Hi,
While migrating wordpress sites from old server to new server such "database error" is very common, if user name for hosting account is different as compare to old server. You must check wp-config.php file to check database name/database user name and database user password.Please check following example for wp-config.php database settings.
Quote:
/** The name of the database for WordPress */
define('DB_NAME', 'test_wrdp1');
/** MySQL database username */
define('DB_USER', 'test_wrdp1');
/** MySQL database password */
define('DB_PASSWORD', 'asdasd3al');
|
Make sure that you are using correct database name,database user name and password as per new server hosting account user name in above example we are using old hosting account user name as "test", if its incorrect for example you have created new hosting account on new server with user name "test123" then create new database,database user name from your control panel and assigned proper privilege to database user to respective wordpress database as well as make respective changes in wp-config.php file. For example check following wp-config.php file after changing user name as per new server hosting account user name "test123".
Quote:
/** The name of the database for WordPress */
define('DB_NAME', 'test123_wrdp1');
/** MySQL database username */
define('DB_USER', 'test123_wrdp1');
/** MySQL database password */
define('DB_PASSWORD', 'asdasd3al');
|
Hope it will resolve your issue, if you are still having any issue then please PM me.