CodeIgniter Forums
Transaction system - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forum-5.html)
+--- Forum: General Help (https://forum.codeigniter.com/forum-24.html)
+--- Thread: Transaction system (/thread-74040.html)



Transaction system - vincent78 - 07-11-2019

I've got a question about the Transaction system
and more precisely, about the trans_rollback() method in a nested transaction

I looked at the code in the DB_driver.php file and it seems that in a nested transaction, a trans_commit() call does the same job than a trans_rollback() call : it just decrements the _trans_depth counter
I agree for the trans_commit() method but for the trans_rollback() method, I expected a rollback for the main transaction

How can I really rollback when I rollback in a nested transaction ?