mysql
, The Command-line Tool
mysqladmin
, Administrating a MySQL Server
mysqlbinlog
, Executing the queries from a binary log
mysqlcheck
for Table Maintenance and Crash Recovery
mysqldump
, Dumping Table Structure and Data
mysqlhotcopy
, Copying MySQL Databases and Tables
mysqlimport
, Importing Data from Text Files
mysqlshow
, Showing Databases, Tables, and Columns
mysql_config
, Get compile options for compiling clients
perror
, Explaining Error Codes
mysqlshow
, Showing Databases, Tables, and Columns
mysqlshow
can be used to quickly look at which databases exist,
their tables, and the table's columns.
With the mysql
program you can get the same information with the
SHOW
commands. See section 4.5.7 SHOW
Syntax.
mysqlshow
is invoked like this:
shell> mysqlshow [OPTIONS] [database [table [column]]]
Note that in newer MySQL versions, you only see those database/tables/columns for which you have some privileges.
If the last argument contains a shell or SQL wildcard (*
,
?
, %
or _
) then only what's matched by the wildcard
is shown. If a database contains underscore(s), those should be escaped
with backslash (some Unix shells will require two), in order to get
tables / columns properly. '*' are converted into SQL '%' wildcard and
'?' into SQL '_' wildcard. This may cause some confusion when you try
to display the columns for a table with a _
as in this case
mysqlshow
only shows you the table names that match the pattern.
This is easily fixed by adding an extra %
last on the
command-line (as a separate argument).