If we want to create a new user in mysql , we can use the following command.
This would create the new user identified by that username and password. This can be validated by logging in again.
So - now we have created this user and password and tested the same.
mysql > create database newdb
> grant all privileges on newdb.* to newuser@"localhost" identified by 'newpassword';
This would create the new user identified by that username and password. This can be validated by logging in again.
mysql > mysql -u newuser -p
Enter password:
So - now we have created this user and password and tested the same.
![Reblog this post [with Zemanta]](http://img.zemanta.com/reblog_e.png?x-id=95e534b0-a7c1-4efc-b107-4dcbbd5d881a)