In http://www.mysql.com/doc/en/News-4.0.6.html
* mysql_change_user() will now reset the connection to the state of a
fresh connect (Ie, ROLLBACK any active transaction, close all temporary
tables, reset all user variables etc..)
So it is in there, starting with version MySQL 4.0.6.
-steve-
-
> If you're using a non-persistent connection, PHP will close the
> connection when the script terminates, and the MySQL server will roll
back
> implicitly. For a non-persistent connection, the connection remains
open
> and you may not see the rollback behavior your expect.
I thought this was fi
On 18-Jun-2003 Becoming Digital wrote:
...
>> if(!mysql_query($array[$i])) {
>> $flag = false;
>>break;
>> }
>>
>> after the loop I do
>> if($flag)
>> mysql_query("commit");
>> else
>> mysql_query("rollback");
>
> Be careful with that last if() statement. I would either change the
>
rom: "Jonas Geiregat" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, 17 June, 2003 15:19
Subject: Re: transactions with php
Becoming Digital wrote:
> I found one item in the PHP Classes Repository that may be of use.
> Unfortunately, the comments are in Span
I'm trying to implement transaction (mysql) in my php code. Could anyone
tell me if this is a good way of using them. I make an array with all
the query's I loop through them. like this mysql_query($qarray[$i])or
die($flag = false);. After the loop I do if($flag) commit; else rollback;
Is this a
gital
www.becomingdigital.com
- Original Message -
From: "Jonas Geiregat" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, 17 June, 2003 13:44
Subject: transactions with php
I'm trying to implement transaction (mysql) in my php code. Could anyone
tell me if this is a good wa
l.com
- Original Message -
From: "Jonas Geiregat" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, 17 June, 2003 13:44
Subject: transactions with php
I'm trying to implement transaction (mysql) in my php code. Could anyone
tell me if this is a good way of
ssage -
From: "Jonas Geiregat" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, 17 June, 2003 13:44
Subject: transactions with php
I'm trying to implement transaction (mysql) in my php code. Could anyone
tell me if this is a good way of using them. I make
At 10:44 -0700 6/17/03, Jonas Geiregat wrote:
I'm trying to implement transaction (mysql) in my php code. Could
anyone tell me if this is a good way of using them. I make an array
with all the query's I loop through them. like this
mysql_query($qarray[$i])or die($flag = false);. After the loop I