The answer from @damp11113 I believe is now outdated. This error message is generated because the user you are attempting to connect with does not have the relevant permissions to do so. (using password: YES)
only means that the user attempted to provide a password during the failed login.
To give all permissions to a MySQL user, type the following into the command line:
mysql -u YourUserName -p
-p
means you will be providing a password. If logging in without a password, do not include -p
. The command line will now prompt you for your password. Then:
GRANT ALL ON YourDatabaseName.* TO 'YourUserName';
And save the changes:
COMMIT;
See also the relevant documentation.