Page 1 of 1

Failed to connect to the database: SQLSTATE[HY000] [1045] Ac

Posted: Sat Jan 14, 2017 1:49 pm
by rajugvb

Hi Guys,
I am getting below error. I don't use root as user id for connection. I use different userid and password for connection.

Error : Failed to connect to the database: SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: YES)

i use below for connection: I still can't understand why get this error. Please help

array (size=10)
'conn' => null
'id' => string 'DB' (length=2)
'type' => string 'MYSQL' (length=5)
'host' => string 'localhost' (length=9)
'port' => int 3306
'user' => string 'mbihandidb' (length=10)
'pass' => string '**********' (length=16)

Thanks in advance.
'db' => string 'ination_db' (length=10)
'qs' => string '' (length=1)
'qe' => string '
' (length=1)


Re: Failed to connect to the database: SQLSTATE[HY000] [1045

Posted: Mon Jan 16, 2017 10:22 am
by mobhar

Make sure your connection info is already correct. Try also to connect to another database in the same server to make sure your connection info is valid.