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.