-2

I got "Access denied for user" error. But I'm checking username and password. It is not localhost.

ERROR SAYS THAT: Failed to connect to MySQL: Access denied for user 'kagangok_me'@'mt-melody-da.guzelhosting.com' (using password: YES)

I am learning how api works.

aynber
  • 22,380
  • 8
  • 50
  • 63

1 Answers1

0

IMHO you can do the following:

  1. Double check user account and password. If account/password is wrong you will get error 1145.

  2. If you are working on a local machine you will need a user like this 'kagangok_me'@'localhost'.

  3. If you can connect and run queries using other tools you can check the existence of a user account by using:

    SHOW GRANTS FOR 'kagangok_me'@'mt-melody-da.guzelhosting.com'
    
    • If your account is OK you may get a result like

      GRANT ALL PRIVILEGES ON . TO ...

    • Otherwise you will get

      1141 - There is no such grant defined for user ...

  4. Contact your DB server administrator in case you have one.

AmigoJack
  • 5,234
  • 1
  • 15
  • 31
Ehab
  • 284
  • 1
  • 9