ADOdb

Database Abstraction Layer for PHP

User Tools

Site Tools


v5:userguide:learn_abstraction:record_insertion

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revisionBoth sides next revision
v5:userguide:learn_abstraction:record_insertion [2016/03/15 17:47] – [AutoExecute] review dregadv5:userguide:learn_abstraction:record_insertion [2016/03/15 17:50] – [Updating Multiple Records] use a complete PHP statement for multiple records update dregad
Line 49: Line 49:
 If the record match statement produces a non-unique result set, then **ALL** records that match will be updated. If the record match statement produces a non-unique result set, then **ALL** records that match will be updated.
  
-  "last_name like 'Sm%'"; +<code php> 
 +$db->autoExecute($table, $record, 'UPDATE', "last_name like 'Sm%'")
 +</code>
 ===== Limitations ===== ===== Limitations =====
 AutoExecute is designed to be used as a UX helper, and contains multiple layers of validation which may cause performance issues. For improved performance, use can be made of [[v5:reference:connection:getinsertsql|getInsertSql()]] and [[v5:reference:connection:getupdatesql|getUpdateSql()]]. In OLTP environments, consider crafting inserts/updates programatically and using [[v5:reference:connection:execute|execute()]]   AutoExecute is designed to be used as a UX helper, and contains multiple layers of validation which may cause performance issues. For improved performance, use can be made of [[v5:reference:connection:getinsertsql|getInsertSql()]] and [[v5:reference:connection:getupdatesql|getUpdateSql()]]. In OLTP environments, consider crafting inserts/updates programatically and using [[v5:reference:connection:execute|execute()]]  
v5/userguide/learn_abstraction/record_insertion.txt · Last modified: 2016/03/20 16:48 by mnewnham