Magento db configration file reads from wrong db
I have two magento instances where the first instance db config file (local.xml) have been modified by mistake to read from the second instance db which in turn redirects the first instance to the second instance main store and admin panel.. I tried fixing it back to read from the its original db but changes aren't happening since I can access the admin panel and the main url fro the first instance redirects to the second .. any work around on how to fix this