Here are some very basic commands that you will find useful for managing MySQL users and DB from the mysql CLI.
To create a user :
-------------------
CREATE USER 'test'@'localhost' IDENTIFIED BY 'password';
-------------------
To create a Database :
-------------------
create database testdb;
-------------------
To display users :
-------------------
SELECT user FROM mysql.user;
-------------------
To delete user and DB or Table :
-------------------
DELETE FROM user where user='test';
FLUSH PRIVILEGES;
-------------------
drop database testdb;
drop table testtable;
-------------------
Please refer the following thread from our forum and others for more detailed commands.
The following sites have comman FAQ and references which might interest you.

Leave a comment: