mysql 某用户对某张表的权限查询

MySql 码拜 8年前 (2016-02-05) 4678次浏览
本人把一张表的查询权限赋给了testuser,
执行语句为:
grant select on testdb.myTesttable  to testuser@”%” identified by “Xyz#123456”;
然后本人查询这个用户的权限
mysql> show grants for testuser;
+–+
| Grants for testuser@%                |
+–+
| GRANT USAGE ON *.* TO “testuser”@”%” |
+–+
1 row in set (0.00 sec)
上面这些信息对本人来说,是没用的,本人想知道的是testuser能否有查询myTesttable的权限
问一下mysql 怎么才能查寻某用户对某张表的权限呢?
解决方案

40

select * from mysql.tables_priv

CodeBye 版权所有丨如未注明 , 均为原创丨本网站采用BY-NC-SA协议进行授权 , 转载请注明mysql 某用户对某张表的权限查询
喜欢 (0)
[1034331897@qq.com]
分享 (0)