I was trying to backup a database with the name test.
I got the error as below:

ERROR 1064 (42000): You have an error in your SQL syntax; check......

This error occurred when I am executing (command line)
mysql> mysqldump -u root -p password test > test.sql;

How could this be solve?

Recommended Answers

All 3 Replies

This query should be run on OS command line not in MySQL.

Where should I point my command line to?
Is it suppose to be C:\> instead of mysql> ?

Thanks for the reply... I figured it out how I am suppose to run the command! :)

In my case, it is C:\xampp\mysql\bin>. The folder than contain mysqldump.exe

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.