how can use mysql transaction in cakephp (without using saveall() method)? using cakephp version 1.2 have searched lot did not example if knows please me in advance ...
here's blog post examples : http://monmonja.com/blog/2008/07/transaction-on-cakephp-12/
i recommend upgrade 1.3 though. cakephp 2.0 coming out soon. manual entry 1.3 here : http://book.cakephp.org/view/1633/transactions
update
cakephp 2.0 similar - http://book.cakephp.org/2.0/en/models/transactions.html
$datasource = $this->getdatasource(); $datasource->begin(); // perform tasks if (/*all's well*/) { $datasource->commit(); } else { $datasource->rollback(); }
Comments
Post a Comment