hanfeng.name

I am a software engineer with interests in web applications.

MySQL数据库管理

MySQL权限

mysql> grant all privileges on laravel5.* to [email protected] identified by 'secret' with grant option;
flush privileges;
  • 用户名:laravel
  • 密码: secret
  • 授权:数据库laravel5的所有表的所有权限

创建用户

grant all privileges on *.* to [email protected] identified by 'dev' with grant option;
grant select on jikedb.* to [email protected] identified by '123';

刷新权限

flush privileges;

回收权限

revoke select on jikedb.* from [email protected];

删除用户

drop user [email protected];

查看用户权限

show grants for [email protected];

参考链接

分配权限

Comments