Bug 810627 - mysql_install_db fails with sql-mode NO_BACKSLASH_ESCAPES
Summary: mysql_install_db fails with sql-mode NO_BACKSLASH_ESCAPES
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: mysql
Version: 16
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Tom Lane
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-04-07 11:05 UTC by Jon Dufresne
Modified: 2012-04-07 15:42 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-04-07 15:42:05 UTC
Type: Bug


Attachments (Terms of Use)

Description Jon Dufresne 2012-04-07 11:05:00 UTC
Description of problem:
In /etc/my.cnf set sql-mode to NO_BACKSLASH_ESCAPES:

sql-mode=NO_BACKSLASH_ESCAPES

Once set run mysql_install_db. Some SQL fails, but the install continues.

# mysql_install_db 
Installing MySQL system tables...
OK
Filling help tables...
ERROR: 1064  You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'abc\'), UNHEX(HEX(\'abc\'));\n        -> \'abc\', 616263, \'abc\'\nmysql> SELECT' at line 1
120407  3:57:42 [ERROR] Aborting

120407  3:57:42 [Note] /usr/libexec/mysqld: Shutdown complete

...

Version-Release number of selected component (if applicable):
$ rpm -qa mysql\*
mysql-server-5.5.21-1.fc16.x86_64
mysql-embedded-5.5.21-1.fc16.x86_64
mysql-connector-odbc-5.1.8-3.fc16.x86_64
mysql-5.5.21-1.fc16.x86_64
mysql-libs-5.5.21-1.fc16.x86_64

How reproducible:
100%

Comment 1 Tom Lane 2012-04-07 14:45:06 UTC
This does not look to me like an error in the Fedora packaging of mysql, but an unsupported case in the upstream code.  If you think it's important for it to work, I'd suggest filing a bug upstream at bugs.mysql.com.

Comment 2 Jon Dufresne 2012-04-07 15:42:05 UTC
Filed upstream bug. http://bugs.mysql.com/bug.php?id=64899


Note You need to log in before you can comment on or make changes to this bug.