Magento 1.9 – SQLSTATE[HY000] [1049] Unknown Database After Deleting local.xml

local.xmlmagento-1.9

I'm using Magento 1.9 need to reconfigure. So I deleted local.xml file but then it shows following error.

SQLSTATE[HY000] [1049] Unknown database 'site_db'

Why this happens?

Best Answer

As error say it's seems that you have not created the database site_db make sure all db details are correct in app/etc/local.xml.If all the info correct then you need to delete var/cache folder.