Bug #1028 mysqldump does not escape possible column name "DESC"
Submitted: 11 Aug 2003 8:13 Modified: 11 Aug 2003 8:30
Reporter: Eric Bellotti Email Updates:
Status: Duplicate Impact on me:
Category:MySQL Server: mysqldump Command-line Client Severity:S3 (Non-critical)
Version:3.23.56 OS:Linux (redhat-linux-gnu)
Assigned to: CPU Architecture:Any

[11 Aug 2003 8:13] Eric Bellotti
if a table contains a column named "DESC", mysqldump will not escape it properly.  The same applies with column name "replace".
This means that a subsequent mysql << mydump.sql will fail with a syntax error.

Note that I MYSQLDUMP'ed from:

/usr/local/mysql/bin/mysqldump  Ver 9.08 Distrib 4.0.13, for unknown-freebsd5.0 (i386)

And I attempted to "import" using:
mysql  Ver 11.18 Distrib 3.23.56, for redhat-linux-gnu (i386)

How to repeat:
create table with column named "desc" or "replace" as a column name.

Suggested fix:
Any column whose name is a reserved keyword should be escaped by mysqldump with backquotes: `DESC` instead of DESC.
[11 Aug 2003 8:30] Alexander Keremidarski
Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. Because of this, we hope you add your comments
to the original bug instead.

Thank you for your interest in MySQL.

Same as #997 and #830.

Please read manual before posting to http://bugs.mysql.com 
Bugs database is not manual refference point.