语法:
create user 用户名@"ip地址" "identified" by 密码;
举例:
create user tom@"192.168.101" identified by "123";
创建除本机以外其他ip第能登入
create user 用户名@"%" "identified" by 密码;
grant all on *.* to toms@"%" identified by "123";
REVOKE all privileges [column] on 库名.表名 from user@"host";
column 不填表示所有字段
drop user@"host"
flush privileges; 刷新权限表 一些时候权限信息可能会有所延迟 可以执行该语句立即刷新权限信息