Hein wrote:Which error are you receiving?> Hi All
> Apologies for a seriously newbie quesion, but I've been doing so many
> installations and all have the same problem.
> When i try to connect using mysql command line:
> mysql --user=cde --password=cde --database=CDE --host=192.168.10.52
> It works fine.
> However, when I try to use localhost as the host name I receive an
> mysql --user=cde --password=cde --database=CDE --host=localhost
> The user I have created is cde% - surely this should catch all hosts?
> I've also tried creating a cdelocalhost user, no luck.
> I dont want to hardcode the IP address in my code, so PLEASE help.
> Thanks in advance!
If it says that your user is not authorized, probably you still have anonymous users in your database.
You should remove them, either manually as described in this page:
or using the mysql_secure_installation script which is provided with recent MySQL packages.
The reason for this conflict is that anonymous users with no password are evaluated before users with passwords
Remove the anonymous users, flush the grant privileges, and try again.
_ _ _ _
(_|| | |(_|>< The Data Charmer