Here is how to quickly create a database and add a user to a mysql database (the mysql console).
(Yes some values need to be changed)
- mysql> use mysql;
- mysql> CREATE DATABASE dbname;
- mysql> INSERT INTO user (Host,User,Password) VALUES (‘localhost’, ‘username’, PASSWORD(‘password’));
- mysql> GRANT ALL ON dbname.* TO ‘username’;
- mysql> FLUSH PRIVILEGES;
- mysql> exit
Update: This approch will not work when using MySQL server under Windows.
Pingback: Naruto Ipod Thingy | Bad Credit - Loans, Repairs, Help, Mortgage news and information.
Pingback: MySQL creating a database and user from the console « Jontas blog …