PHP Classes
elePHPant
Icontem

transaction

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us

      Extended MySQLi  >  All threads  >  transaction  >  (Un) Subscribe thread alerts  
Subject:transaction
Summary:transaction commands(commit,ROLLBACK ) do not cause
Messages:2
Author:Onur
Date:2011-08-20 11:04:47
Update:2012-10-10 15:15:41
 

  1. transaction   Reply   Report abuse  
Picture of Onur Onur - 2011-08-20 11:04:47
transaction commands(commit,ROLLBACK ) do not cause

  2. Re: transaction   Reply   Report abuse  
Picture of Camilo Sperberg Camilo Sperberg - 2012-10-10 15:15:41 - In reply to message 1 from Onur
Hello, sorry for the late reply but I didn't notice this message before.

As far as I have tested, there are some restrictions of MySQL regarding transactions.
- It will only work with InnoDB type tables
- DDL statements (ALTER TABLE; CREATE TABLE; etc) are not a part of transaction, it means that they will do an implicit COMMIT (More info on the link below).
- A maximum of 1023 can be done in one transaction

That are the ones I've been able to detect so far. However, you should read more about this topic on this link:
dev.mysql.com/doc/refman/5.1/en/imp ...

If you want a more complete and robust solution regarding transactions, I seriously recommend you use another RDBMS, such as PostGreSQL for which I have another class where transactions will always work, even DDL statements will execute within a transaction.

Greetings.