mysqlshow lists databases, tables within a database, or information about columns or indexes within a table. It acts as a command-line interface to the SHOW SQL statement.


mysqlshow [options] [db_name [tbl_name [col_name]]] 

If no database name is specified, mysqlshow lists all databases on the server host. If a database name but no table name is specified, all tables in the database are listed. If database and table names are specified but no column name is specified, it lists the columns in the table. If all the names are specified, mysqlshow shows information about the given column.

If the final argument contains a shell wildcard ('*' or '?'), output is limited to values that match the wildcard. '*' and '?' are treated as the '%' and '_' SQL wildcard characters for the LIKE operator. As of MySQL 3.22.26, mysqlshow also interprets '%' and '_' as wildcard characters.

Standard Options Supported by mysqlshow

--character-sets-dir     --host                   --socket 
--compress               --password               --user
--debug                  --pipe                   --verbose
--help                   --port                   --version

--character-sets-dir was added in MySQL 3.23.21. As of MySQL 4, mysqlshow also supports the standard SSL options.

Options Specific to mysqlshow

  • --status, -i (boolean)

    Display the same kind of table information displayed by the SHOW TABLE STATUS statement. This option was introduced in MySQL 3.23.

  • --keys, -k (boolean)

    Show information about table indexes in addition to information about table columns. This option is meaningful only if you specify a table name.