编程爱好者之家

mysql 授权给某个用户某个数据库权限

2022-11-02 14:04:26 180

  mysql 授权给某个用户某个数据库权限怎么操作呢

grant all privileges on 数据库名.* to '用户名'@'%' identified by '密码';

比如说授权给 用户test数据库testsbname所有权,并且设置密码为testpwd可以这样写

grant all privileges on testdbname.* to 'test'@'%' identified by 'testpwd';


同类文章