note 108361 added to pdo.intransaction
| From: | r.hanouwer | Date: | Thu, 19 Apr 2012 18:12:32 +0000 |
| Subject: | note 108361 added to pdo.intransaction | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-187245@lists.php.net to get a copy of this message | ||
Exceptions regarding existing active transactions were thrown while I was almost certain sufficient
checks were in place.
However, I quickly found out that a strict boolean comparison to PDO::inTransaction() was failing.
Using var_dump I learned that this function was returning integers, not boolean values.
var_dump(PDO::inTransaction()); // int(1) || int(0)
----
Server IP: 72.55.140.6
Probable Submitter: 94.212.115.230
----
Manual Page -- http://www.php.net/manual/en/pdo.intransaction.php
Edit -- https://master.php.net/note/edit/108361
Del: integrated -- https://master.php.net/note/delete/108361/integrated
Del: useless -- https://master.php.net/note/delete/108361/useless
Del: bad code -- https://master.php.net/note/delete/108361/bad+code
Del: spam -- https://master.php.net/note/delete/108361/spam
Del: non-english -- https://master.php.net/note/delete/108361/non-english
Del: in docs -- https://master.php.net/note/delete/108361/in+docs
Del: other reasons-- https://master.php.net/note/delete/108361
Reject -- https://master.php.net/note/reject/108361
Search -- https://master.php.net/manage/user-notes.php