mysql创建,修改,删除用户,以及权限设置

1,CREATE USER语法 

 CREATE USER user identified by '123456'

2,DROP USER语法 

drop user user@localhost;

3,SET PASSWORD语法 

set password for user=password('123456');

4,GRANT和REVOKE语法 

grant all privileges on db.* to user@localhost identified by  '123456';

REVOKE ALL PRIVILEGES, GRANT OPTION FROM user@'%';

revoke all privileges on db.*  from  user@'192.168.1.1';

上一篇: 如何找到耗费CPU资源的php程序?   下一篇: css之自动换行

提交疑问

请先登录 QQ微博登录

回顶部