开发者

mysql cli: how to list all databases I have permisions to create/read/update/delete?

What command do I use on a mysql command line to see all the databases on some database server that I have permissions to? Specifically I am looking for the开发者_运维百科 DBs that I have full CRUD permissions to.


mysql -e "show databases"


UPDATE:

Based on your edit, here is a query you can run against the mysql database in your server:

mysql> select Db from db where User='aj' and (select_priv='Y' and insert_priv='Y' and update_priv='Y' and delete_priv='Y');
+---------+
| Db      |
+---------+
| HopeDB  |
| LocusDB |
+---------+
2 rows in set (0.00 sec)
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜