Bug #58562 --lock-tables enabled even when --single-transaction option selected
Submitted: 29 Nov 2010 15:05 Modified: 7 Mar 2011 11:32
Reporter: Leandro Morgado Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench: Administration Severity:S1 (Critical)
Version:5.2.30 OS:Any
Assigned to: Alexander Musienko CPU Architecture:Any

[29 Nov 2010 15:05] Leandro Morgado
Description:
When making a backup with --single-transaction enabled in the Administrator plugin, I see that --lock-tables is still set to TRUE:

14:47:31 Dumping world (City, v1, v2)
Running: "/Applications/MySQLWorkbench.app/Contents/Resources/mysqldump" --defaults-extra-file="/var/folders/3u/3uNl0zNSGcG92SteUBv00E+++TI/-Tmp-/tmpEab3LG/extraparams"  --no-create-info=FALSE --order-by-primary=FALSE --force=FALSE --no-data=FALSE --tz-utc=TRUE --flush-privileges=FALSE --compress=FALSE --replace=FALSE --host=localhost --insert-ignore=FALSE --extended-insert=TRUE --user=root --quote-names=TRUE --hex-blob=FALSE --complete-insert=FALSE --add-locks=TRUE --port=3306 --disable-keys=TRUE --delayed-insert=FALSE --create-options=TRUE --delete-master-logs=FALSE --comments=TRUE --default-character-set=utf8 --max_allowed_packet=1G --flush-logs=FALSE --dump-date=TRUE --lock-tables=TRUE --allow-keywords=FALSE --events=FALSE --single-transaction=TRUE "world" "City" "v1" "v2"

However, the mysqldump manual says:

"The --single-transaction option and the --lock-tables option are mutually exclusive because LOCK TABLES causes any pending transactions to be committed implicitly. "
  http://dev.mysql.com/doc/refman/5.1/en/mysqldump.html

How to repeat:
Select "Create Dump in Single Transaction" in the Export to Disk tab. Observe Log.

Suggested fix:
Don't use --lock-tables when --single-transaction is enabled.
[3 Mar 2011 13:39] Johannes Taxacher
fix confirmed in repository
[7 Mar 2011 11:32] Tony Bedford
An entry has been added to the 5.2.32 changelog: 

In the Administrator, when making a backup with the option 
<option>--single-transaction</option> enabled, the option 
<option>--lock-tables</option> was erroneously still enabled.