To grant all priveleges on the database: mydb
to the user: myuser
, just execute:
GRANT ALL ON mydb.* TO 'myuser'@'localhost';
or:
GRANT ALL PRIVILEGES ON mydb.* TO 'myuser'@'localhost';
The PRIVILEGES
keyword is not necessary.
Also I do not know why the other answers suggest that the IDENTIFIED BY 'password'
be put on the end of the command. I believe that it is not required.