1. 查看所有用户信息
select * from mysql.user;
2. 创建用户账号及密码
create user 'test'@'localhost' identified by '123456';
3. 查看用户权限
show grants for test@localhost;
4. 授权用户所有权限
grant all privileges on `table_name`.* to 'test'@'localhost';
5. 删除用户以及对应的权限
drop user test@'127.0.0.1';
6. 刷新
flush privileges;