Show open tables;
Based on my use of MySQL, the commonly used MySQL show statements are listed as follows:
1.show databases; Displays the names of all databases in MySQL
2.show tables [from database_name]; Displays the names of all tables in the current database
3.show columns from table_name; Show column names in table, same as DESC tablename
4.show [FULL] processlist;//all process information that is running
5.show grants for USER_NAME; Displays the permissions of a user, displaying results similar to the grant command
6.show [GLOABL | session] variables [like '%keyword% ']; Display the name and value of a system variable
7.show [GLOABL | session] status [like '%keyword% ']; Provides server state information. With the global option, you can get status values for all MySQL connections. Using the session, you can get all the status values for the current connection. The default is session.
8.show index from Tb_name [from db_name]; Index of the display table
9.show privileges; Display the permissions supported by the server
10.show table status [from db_name] [like '%keyword% ']; Displays information about each table in the current database or in the specified databases, including the table type, creation time, and the last updated time of the table.
11.show CREATE DATABASE database_name; Display the CREATE DATABASE statement
12.show CREATE TABLE Tab_name; Display the CREATE TABLE statement
13.show InnoDB status; Displays the status of the InnoDB storage engine
14.show logs; Displaying logs for the BDB storage engine
15.show warnings; Displays errors, warnings, and notifications resulting from the last statement executed
16.show errors; Displays the error resulting from the last execution of the statement
17.sHow character set [like '%pattern% '];// used to display the available character sets, like to match the CharSet field of a table
18.show collation [like ' latin1% ']; // to show how all available character sets are sorted, like to match the collation field in a table.
19.show full columns from tab_name [like '%user% '];// displays the information for each column in a given table, the full keyword causes the output to contain the permissions you have, and contains the comments for each column, like to match the column names.
.Show engine InnoDB logs;//Display log or status information for the storage engine
.Show [storage] engines;//Displays status information for the storage engine. You can see if a storage engine is supported, and what the default engine is.
.Show grants;
Show grants for username;
show grants for Current_User;
Show grants for Current_User ();
23.show Open tables [from dbname] [like '%keyword% '];// lists the non-temporary tables that are currently open in the table cache.
24.show triggers [from db_name] [like '%keyword% '];//lists the triggers currently defined by the MySQL server. The expression (expr) to be matched by the LIKE clause is compared to the name of the table in which the trigger was defined, not to the name of the triggering program.
25.show CREATE PROCEDURE sp_name;//Show details about a stored procedure
MySQL Show statement Daquan