MySQL Error Invalid Table or Database Name

We upgraded our MySQL server recently which ran several Joomla web sites

After the upgrade we discovered the following error in the mysql log files

090425 23:10:52 [ERROR] Invalid (old?) table or database name 'database-name'

It turns out MySQL does not like the use of - in database names.

One solution is to rename the MySQL database changing the - to an _

Then update the mysql dictionary

UPDATE mysql.db SET Db = 'database_name' WHERE Db = 'database\-name';


  1. I am really enjoying reading your well written articles.
    It looks like you spend a lot of effort and time on your blog.
    I have bookmarked it and I am looking forward to reading new articles. Keep up the good work..
    ccna Training in Chennai
    ccna Training institute in Chennai
    Angularjs Course in Chennai
    Ethical Hacking Course in Chennai
    Tally Course in Chennai
    ccna course in chennai
    ccna training in chennai

  2. Everything is very open with a precise explanation of the issues. It was really informative. Your site is very useful. Thanks for sharing!


Post a Comment

Popular posts from this blog

ActiveMQ, easy to use open source message oriented middleware (MOM)

Basic Send Message to MQ with Java and IBM MQ JMS

Automated Service Monitoring with F5, Consul and Python F5 SDK