Bug #1763 backup with mysqldump
Submitted: 6 Nov 2003 2:46 Modified: 22 Nov 2003 2:46
Reporter: [ name withheld ] Email Updates:
Status: Won't fix Impact on me:
None 
Category:MySQL Server: mysqldump Command-line Client Severity:S2 (Serious)
Version:mysqldump ver 8.21 Distrib 3.23.48 OS:Linux (suse-linux)
Assigned to: Ramil Kalimullin CPU Architecture:Any

[6 Nov 2003 2:46] [ name withheld ]
Description:
I have a problem with the --disable-keys option. this creates an statement like: /*!40000 ALTER TABLE tb_name DISABLE KEYS */;
the problem ist, that i use an mysql older than 4.00 and i get an error "query was empty" when i execute the script. 
you can move around this problem with the --force option, but it is not nice. 
why isn't the semicolon whithin the comments?
is this a bug? and is it fixed yet?

mysqldump ver 8.21 Distrib 3.23.48
mysql ver 11.15 distrib 3.23.48
mysqld ver 3.23.48

How to repeat:
create backup with the --disable-keys option.
execute the created script.

Suggested fix:
move the semicolon within the comments.
[21 Nov 2003 8:39] MySQL Verification Team
Same behavior with version 9.09
[22 Nov 2003 2:46] Sergei Golubchik
this is a known issue.

The problem is that when semicolon is inside the comment it doesn't work with mysqld versions newer than 4.0

We fixed it some time ago by allowing an "empty" query, it is not an error anymore. From the manual:

Changes in release 3.23.49
--------------------------

   * Don't give warning for a statement that is only a comment; this is
     needed for `mysqldump --disable-keys' to work.