I want to backup my database using mysql dump. This is the code I run in Command prompt when the location is mysql bin.
mysqldump -u root -pabc Db -r C:\Documents and Settings\All Users\Desktop\ttttt.sql
abc is the password. and I try to backup to a .sql file in desktop. I use mysql 5.5.
But the following error occured. mysqldump: Couldn't find table: "and"
But there is no table called 'and' in database and I didn't create such a table.But the error say about a 'and' table. How can I back up mysql database without this error.
Add a comment
|
2 Answers
Try instead:
mysqldump -u root -pabc Db -r "C:\Documents and Settings\All Users\Desktop\ttttt.sql"
Your command shell is breaking apart the pathname into multiple arguments. The quotes tell the shell to pass it all as a single argument to the mysqldump program.
2 Comments
Débora
Thank you very much. It worked. But Ealier the code I showed in my question worked well when the OS is Windows 7.But when I run the same, in windows XP, It didn't worked. I think there is something in OS as well.Your code worked well in XP .Thank you once again
sarnold
It could be that Microsoft extended the shell to recognize this exact situation and spare you the quotes. But I'm not too familiar with newer Windows.