Portal Home > Knowledgebase > Articles Database > Mysql not getting detected


Mysql not getting detected




Posted by rankris, 07-20-2010, 07:19 PM
few of my databases are not getting recognized by the mysql server on my plesk VPS, the db is there on /var/lib/mysql but not getting identified as db, what coupe be the reason? How to fix this?

Posted by Encrypted, 07-20-2010, 07:24 PM
Are you positive they exist? I was playing around with LAMP on my system yesterday and I got warnings that my database was not found prior to creating it and then restoring my .sql file. Make sure you create an empty db before restoring it and also make sure you assign a user to the database and add all of the permissions. I have a funny feeling either not having a user assigned to the db or not setting the proper permissions is going to be the issue here.

Posted by rankris, 07-20-2010, 07:27 PM
it is there , I tried creating the same database but it says syntax not correct as the db present is having a - in its name

Posted by Encrypted, 07-20-2010, 09:55 PM
Hmm, try to rename the database. http://dev.mysql.com/doc/refman/5.1/...-database.html (might not need to do the following, but if it still doesn't work, try it) Then do a mysqldump, delete the database, create the database again, and do a mysql restore.

Posted by madaboutlinux, 07-21-2010, 08:04 AM
Right, hypen ( - ) is considered as a special character and hence Mysql won't detect it as a database. If you connect to Mysql server and execute the command: you will see the database not detected by Mysql is present with some non-alphanumeric characters. The better solution is to create a new database without special characters and restore the tables.

Posted by Isaac Newton, 07-21-2010, 01:48 PM
Has the issue got fixed after renaming the database without the hyphen? Just curious. In case if it is still not working, make sure the database has got its privileges correct.



Was this answer helpful?

Add to Favourites Add to Favourites    Print this Article Print this Article

Also Read
Java Servelets (Views: 753)


Language:

LoadingRetrieving latest tweet...

Back to Top Copyright © 2018 DC International LLC. - All Rights Reserved.