开发者

Show only user created tables in MySQL?

Is there a SQL command by which I can display only the tables created by users and excluding those present by defau开发者_运维百科lt in the MySQL database?


This about wraps it up:

select * from information_schema.tables 
where table_schema not in ('information_schema', 'mysql', 'performance_schema')

The information_schema contains meta-information about your database. You can list all tables using information_schema.tables. If you exclude the two meta-schemas information_schema, and mysql, you'll get all user-tables

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜