Access Denied for user using password: YES

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
segnew
Posts: 6
Joined: Thu 14 Jan 2010 14:54

Access Denied for user using password: YES

Post by segnew » Wed 17 Mar 2010 17:15

Hello:

I dropped a TMyConnection on my form and set the user and server information. I set the password and set LoginPrompt to False. When I attempt to connect I get the following message:

#28000Access denied for user 'host@'localhost' (using password: YES)

When I set LoginPrompt to True and attempt to connect the result is the same. I have no problem connecting through DBForge Studio.

The password is not "YES". Another user submitted a similar problem but you answered by email. They said they were getting "using password: NO)".

I am using Delphi 2007 enterprise and myDac 5.90.0.56 with MySQL Essentials 5.1.45 for windows 32. The operating system is Windows Vista Ultimate.

Thanks.

segnew
Posts: 6
Joined: Thu 14 Jan 2010 14:54

Post by segnew » Thu 18 Mar 2010 04:26

Problem resolved. I was using the wrong username.

Tarakan
Posts: 1
Joined: Wed 19 Jun 2013 18:32

Re: Access Denied for user using password: YES

Post by Tarakan » Thu 20 Jun 2013 08:21

I have a similar problem, but I can't enter a correct user name. When I write the correct short name (without @...), it adds @ and some ip after it. It does the same even if I input the full name with @ - then in the resulting user name there will be two @. When trying to connect by ip, not by the address, I get "serwer has not replied", or something like that, but it seemed to be the host's problem. How can I input the correct name and not to let the program to add @... to it, or any way to edit that part.

DemetrionQ
Devart Team
Posts: 271
Joined: Wed 23 Jan 2013 11:21

Re: Access Denied for user using password: YES

Post by DemetrionQ » Fri 21 Jun 2013 10:50

Hello.

    When sending login to server, the @ symbol is not added to it (and you shouldn't add the @ symbol or the PC name to it). The 'YourUserName'@'YourComputerName' message is a server response to an authentication fail. This message means that no user with the 'YourUserName' name exists or you have entered an invalid password, or a user with the 'YourUserName' name has no server access rights from the 'YourComputerName' PC.

    To solve the problem, you should add the necessary rights to the YourUserName account or create a user with the necessary rights. The needed information can be found in the MySQL reference manual (e.g.: http://dev.mysql.com/doc/refman/5.5/en/grant.html).

Post Reply