创建用户:create user 'user1'@'%' identified by 'howhy@123';
删除用户:drop user 'user1'@'%' ;
查看当前用户权限:show grants;
查看用户权限:show grants for 'user1'@'%';
给用户授权:grant select,update,insert,delete on iqiyi.* to 'user1'@'%';
修改用户密码:alter user 'user1'@'%' identified by '123@howhy';
收回或删除权限:alter user 'user1'@'%' identified by '123@howhy';
8.0角色 :
create role app_dev;
grant all on *.* to app_dev with grant option;
grant app_dev to 'user1'@'%';