I am using mysql5.1 server. I want to import sql dumb file using command prompt. and I also tried the following,
MySQL> -u {username} -p {database_name} < filename
am getting an error for the above code.
I am using mysql5.1 server. I want to import sql dumb file using command prompt. and I also tried the following,
MySQL> -u {username} -p {database_name} < filename
am getting an error for the above code.
filename.sql
should be in server. You can load the data if your filename.sql
in client.
Finally found an answer for my question. we could import the dumb file in the following way:
1.From the command prompt go to the root of the server
C:\Program Files\MySQL\MySQL Server 5.1\bin>
2.Load the dumb file into the server using following command
bin>mysql -uroot -p<server_password> {database_name} < {complete filepath}
Example:bin>MySQL -uroot -ppassword mydb < C:\Users\Anto\Documents\DB_Dumb