Skip Menu |

This queue is for tickets about the DBD-mysql CPAN distribution.

Report information
The Basics
Id: 105382
Status: resolved
Priority: 0/
Queue: DBD-mysql

Owner: CAPTTOFU [...]
Requestors: j.raspass [...]
Cc: k.spice [...]
t.retout [...]

Bug Information
Severity: (no value)
Broken in: 4.031
Fixed in: (no value)

CC: k.spice [...], t.retout [...]
Subject: AutoCommit isn't restored after reconnect when starting a transaction
Download (untitled) / with headers
text/plain 638b
If the first command on a disconnected handle with auto_reconnect set is a begin_work it will be die like so: perl -MDBI -e 'my$d=DBI->connect("DBI:mysql:host=xxx","xxx","xxx",{mysql_auto_reconnect=>1});$d->disconnect;$d->begin_work;$d->commit' DBD::mysql::db begin_work failed: Turning off AutoCommit failed at -e line 1. However if you do anything else before starting the transaction then all is well: perl -MDBI -e 'my$d=DBI->connect("","root","defiant1764",{mysql_auto_reconnect=>1});$d->disconnect;$d->do("SELECT 1");$d->begin_work;$d->commit' Tested on perl 5.14.2 with DBD::mysql 4.031
Download (untitled) / with headers
text/plain 127b
Ah yes, accidental leakage of the test DB's credentials in that bug report, those credentials have now been retired. Whoops :-P
Download (untitled) / with headers
text/plain 343b
Do we have any progress on this? The problem still exists in 4.041. It doesn't look like there was in fix in 4.042, but can anyone confirm that? I appreciate that this may not be the most important development problem right now but I can confirm, fortunately, that the simple workaround seems to work well. Thanks, James, for including it.
Yes, thank you for reminding me. I'll be looking at this.

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to