mysql gives me the syntax error with the following line... i dont know what is wrong with this...
mysqldump -u root -p root mydatabase > dumpfile.sql
i am using windows vista...
plz help here.. thnx..
mysql gives me the syntax error with the following line... i dont know what is wrong with this...
mysqldump -u root -p root mydatabase > dumpfile.sql
i am using windows vista...
plz help here.. thnx..
The -p
part is the problem. From the manual:
The password to use when connecting to the server. If you use the short option form (-p), you cannot have a space between the option and the password. If you omit the password value following the --password or -p option on the command line, you are prompted for one.
Try
mysqldump -u root -proot mydatabase > dumpfile.sql
But in the future, please ask a proper question including any error messages you get (you certainly got one in this case) so people don't have to guess.
Make sure that you are running this from the normal command line and not within the mysql command line. So like this:
C:\[path to mysqldump app] > mysqldump -u root -p root mydatabase > dumpfile.sql
not
mysql > mysqldump -u root -p root mydatabase > dumpfile.sql