Hi, I have used the following code to get xml output from mysql. Code: >mysql -u root -X -e "select * from xxx" database_name; But i get the following error, Code: ERROR:1049<42000>:unknown database 'database_name;'
As far as the syntax is concerned, it is correct. But the above error occurs only when the database that you are trying to use "database_name" doesn't exist. You should check whether you have specified the correct database name and then try the command again.
Hi venami, Thanks for the reply.I got it solved by removing semicolon at the end of the statement. Thanks.
Very good I still remember me doing the same mistake a long time ago I missed to notice it in your error statement