简体   繁体   中英

Check database schemas mysql

有没有在MySQL命令行客户端的Windows命令,允许您查看数据库中的所有表,或显示特定表的模式,类似于.tables在sqlite3的或\\dt在psql里?

show tables;

要么

select table_name from information_schema.tables where table_schema = 'your_db'

[misread]

You're looking for SHOW TABLES it sounds like.

To see the schema of a table, use DESCRIBE table_name;

就像其他人所说的那样,如果要查看特定表的架构,请使用

SHOW CREATE TABLE foobar;

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM