How to set your Magento SQL Connection Path
The easy way to set your MySQL path in Magento is by editing the /app/etc/local.xml file with your new details. A good example when you may need this is if your are migrating Magento across servers.
<default_setup>
<connection>
<host><![CDATA[localhost]]></host>
<username><![CDATA[username]]></username>
<password><![CDATA[password]]></password>
<dbname><![CDATA[database]]></dbname>
<active>1</active>
</connection>
</default_setup>

(4.75 out of 5)