Re: MDB2 transaction misconfiguration with mysql
| From: | Lukas Kahwe Smith | Date: | Thu, 06 Sep 2007 14:17:55 +0000 |
| Subject: | Re: MDB2 transaction misconfiguration with mysql | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-27886@lists.php.net to get a copy of this message | ||
fusillo wrote:
I use singleton to set the mdb2 object $mdb2=&MDB2::singleton($dsn,array('default_table_type'=>'InnoDB','use_transactions'=>true)); and this initializazion of MDB2 object works like factory(), that is use lazy connection to the db, then the connect() method is call only after a statement requiring to query dbms. Then to resolve the problem it's enough to force the connection with this line of code: $mdb2->connect();Ah, right. Amazing how quickly I forget my own code. regards, Lukas