MySQL and Unity: Access Denied

Viewed 127

I am trying to read a database on a MySQL server, with Unity.

My string connection in Unity is:

string connectdb = "server=**.**.**.**;" +"user=PLAYER;"+"database=****_database;"+"port=15;"+"password=psw"+ "CharSet = utf8mb4;";

And when I try to connect a get the error :

Access denied for user 'PLAYER'@'*********************' (using password: YES)

In MySQL server I grant all privileges to 'PLAYER', to any IP address. As you can see, it work on localhost:

As you can see, it work on localhost

And of course, I comment the line of blind address:

ok

And it denied access. Why might this be?

1 Answers

It's probably because you're specifying a password in your connection string: "password=psw"

Change this for null or remove the password key entirely.

Related