Doc #62503 [Opn->Csd]: DDL statements in PDO queries are implicitly commited!
| From: | aharvey@php.net | Date: | Fri, 20 Jul 2012 06:21:33 +0000 |
| Subject: | Doc #62503 [Opn->Csd]: DDL statements in PDO queries are implicitly commited! | ||
| References: | 1 | Groups: | php.doc.bugs |
| Request: | Send a blank email to doc-bugs+get-8600@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=62503&edit=1
ID: 62503
Updated by: aharvey@php.net
Reported by: kotai dot kristof at gmail dot com
Summary: DDL statements in PDO queries are implicitly
commited!
-Status: Open
+Status: Closed
Type: Documentation Problem
Package: PDO related
Operating System: Win
PHP Version: Irrelevant
-Assigned To:
+Assigned To: aharvey
Block user comment: N
Private report: N
New Comment:
This bug has been fixed in SVN.
Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
For Windows:
http://windows.php.net/snapshots/
Thank you for the report, and for helping us make PHP better.
Previous Comments:
------------------------------------------------------------------------
[2012-07-20 06:20:54] aharvey@php.net
Automatic comment from SVN on behalf of aharvey
Revision: http://svn.php.net/viewvc/?view=revision&revision=326723
Log: Fix doc bug #62503 (DDL statements in PDO queries are implicitly commited!).
------------------------------------------------------------------------
[2012-07-08 21:06:13] johannes@php.net
Note: Some DBMSs allow DDL in transactions. But yes, a better example woud be good. btw. if you want
that to happen faster: go to https://edit.php.net/?project=PHP&perm=en/pdo.commit.php
and propose an better example!
------------------------------------------------------------------------
[2012-07-07 20:56:51] kotai dot kristof at gmail dot com
Description:
------------
---
From manual page: http://www.php.net/pdo.commit#refsect1-pdo.commit-examples
---
In the manual on this page: http://www.php.net/manual/en/pdo.commit.php
In the first example, the code is very misleading. Because DDL statements in PDO
queries are always implicitly commited! So the commit() call after the exec() call
makes no difference.
Instead use an INSERT, UPDATE or DELETE query pls.
Test script:
---------------
not required
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=62503&edit=1