Reputation: 21443
Is there a command in the MySQL command line client for windows that allows you to view all tables in a database, or display the schema of a particular table, similar to .tables
in sqlite3 or \dt
in psql?
Upvotes: 4
Views: 41411
Reputation: 13914
[misread]
You're looking for SHOW TABLES
it sounds like.
To see the schema of a table, use DESCRIBE table_name;
Upvotes: 8
Reputation: 23848
As the other said for the table list - if you want to see schema of a particular table use
SHOW CREATE TABLE foobar;
Upvotes: 5
Reputation: 56357
show tables;
or
select table_name from information_schema.tables where table_schema = 'your_db'
Upvotes: 7