I’m following a text tutorial, where I create a user:
create user 'APP'@'localhost' identified by 'APP';
grant all privileges on *.* to 'APP'@'localhost';
quit
When I try to login to the user with:
mysql -u APP -p
I’m asked a password. Entering the password give me the error:
ERROR 1045 (28000): Access denied for user 'APP'@'localhost' (using password: YES)
Which password does the created user have?
>Solution :
The identified by portion is where you are setting a password for a user. So ‘APP’ is the password.
Edit: You may also need to execute FLUSH PRIVILEGES; for the change to take affect.