List:General Discussion« Previous MessageNext Message »
From:Ian Collins Date:October 12 2006 2:03am
Subject:mysqldump quotes in MySQL 5.0.26
View as plain text  
Hi,
I have 2 identical Linux machines setup with identical my.cnf files 
(except for server-id) and both running 5.0.26.

On server A, I run,

mysqldump -h localhost -u root -p... --single-transaction --flush-logs 
--delete-master-logs --master-data=1 --databases db1 db2 > dumpfile

I copy dumpfile to server B
and extract with,

mysqladmin -u root -p... create db1
mysqladmin -u root -p... create db2

cat dumpfile | mysql -u root -p...

I get the error,

ERROR 1049 at line 25: Unknown database '`db1`'

Note the backticks around the database name.
Looking at dumpfile, I see,

use `db1`

I tried doing the mysqldump with --compatible=ansi which changes the 
backticks to double quotes, but get the same error,

ERROR 1049 at line 25: Unknown database '"db1"'.

I can't edit dumpfile as it is 8Gb (ok, I can split it and stuff like 
that ... but come on!!)

What am I missing here?  Has anyone else seen this?

Regards,
Ian Collins.



Thread
mysqldump quotes in MySQL 5.0.26Ian Collins12 Oct
  • Re: mysqldump quotes in MySQL 5.0.26Dan Buettner12 Oct
    • Re: mysqldump quotes in MySQL 5.0.26Ian Collins12 Oct