MYSQLSHOW(1) MySQL Database System MYSQLSHOW(1)

2
3
4

NAME

6       mysqlshow - display database, table, and column information
7

SYNOPSIS

9       mysqlshow [options] [db_name [tbl_name [col_name]]]
10

DESCRIPTION

12       The mysqlshow client can be used to quickly see which databases exist,
13       their tables, or a table's columns or indexes.
14
15       mysqlshow provides a command-line interface to several SQL SHOW
16       statements. See Section 5.4, “SHOW Syntax”. The same information can be
17       obtained by using those statements directly. For example, you can issue
18       them from the mysql client program.
19
20       Invoke mysqlshow like this:
21
22          shell> mysqlshow [options] [db_name [tbl_name [col_name]]]
23
24       ·  If no database is given, a list of database names is shown.
25
26       ·  If no table is given, all matching tables in the database are shown.
27
28       ·  If no column is given, all matching columns and column types in the
29          table are shown.
30
31
32       The output displays only the names of those databases, tables, or
33       columns for which you have some privileges.
34
35       If the last argument contains shell or SQL wildcard characters (‘*’,
36       ‘?’, ‘%’, or ‘_’), only those names that are matched by the wildcard
37       are shown. If a database name contains any underscores, those should be
38       escaped with a backslash (some Unix shells require two) to get a list
39       of the proper tables or columns. ‘*’ and ‘?’ characters are converted
40       into SQL ‘%’ and ‘_’ wildcard characters. This might cause some
41       confusion when you try to display the columns for a table with a ‘_’ in
42       the name, because in this case, mysqlshow shows you only the table
43       names that match the pattern. This is easily fixed by adding an extra
44       ‘%’ last on the command line as a separate argument.
45
46       mysqlshow supports the following options:
47
48       ·  --help, -?
49
50          Display a help message and exit.
51
52       ·  --character-sets-dir=path
53
54          The directory where character sets are installed. See Section 8.1,
55          “The Character Set Used for Data and Sorting”.
56
57       ·  --compress, -C
58
59          Compress all information sent between the client and the server if
60          both support compression.
61
62       ·  --count
63
64          Show the number of rows per table. This can be slow for non-MyISAM
65          tables. This option was added in MySQL 5.0.6.
66
67       ·  --debug[=debug_options], -# [debug_options]
68
69          Write a debugging log. The debug_options string often is
70          ´d:t:o,file_name'.
71
72       ·  --default-character-set=charset_name
73
74          Use charset_name as the default character set. See Section 8.1, “The
75          Character Set Used for Data and Sorting”.
76
77       ·  --host=host_name, -h host_name
78
79          Connect to the MySQL server on the given host.
80
81       ·  --keys, -k
82
83          Show table indexes.
84
85       ·  --password[=password], -p[password]
86
87          The password to use when connecting to the server. If you use the
88          short option form (-p), you cannot have a space between the option
89          and the password. If you omit the password value following the
90          --password or -p option on the command line, you are prompted for
91          one.
92
93          Specifying a password on the command line should be considered
94          insecure. See Section 6.6, “Keeping Your Password Secure”.
95
96          Specifying a password on the command line should be considered
97          insecure. See Section 6.6, “Keeping Your Password Secure”.
98
99       ·  --port=port_num, -P port_num
100
101          The TCP/IP port number to use for the connection.
102
103       ·  --protocol={TCP|SOCKET|PIPE|MEMORY}
104
105          The connection protocol to use.
106
107       ·  --show-table-type, -t
108
109          Show a column indicating the table type, as in SHOW FULL TABLES. The
110          type is BASE TABLE or VIEW. This option was added in MySQL 5.0.4.
111
112       ·  --socket=path, -S path
113
114          For connections to localhost, the Unix socket file to use, or, on
115          Windows, the name of the named pipe to use.
116
117       ·  --ssl*
118
119          Options that begin with --ssl specify whether to connect to the
120          server via SSL and indicate where to find SSL keys and certificates.
121          See Section 6.7.3, “SSL Command Options”.
122
123       ·  --status, -i
124
125          Display extra information about each table.
126
127       ·  --user=user_name, -u user_name
128
129          The MySQL username to use when connecting to the server.
130
131       ·  --verbose, -v
132
133          Verbose mode. Print more information about what the program does.
134          This option can be used multiple times to increase the amount of
135          information.
136
137       ·  --version, -V
138
139          Display version information and exit.
140
142       Copyright 1997-2007 MySQL AB
143
144       This documentation is NOT distributed under a GPL license. Use of this
145       documentation is subject to the following terms: You may create a
146       printed copy of this documentation solely for your own personal use.
147       Conversion to other formats is allowed as long as the actual content is
148       not altered or edited in any way. You shall not publish or distribute
149       this documentation in any form or on any media, except if you
150       distribute the documentation in a manner similar to how MySQL
151       disseminates it (that is, electronically for download on a Web site
152       with the software) or on a CD-ROM or similar medium, provided however
153       that the documentation is disseminated together with the software on
154       the same medium. Any other use, such as any dissemination of printed
155       copies or use of this documentation, in whole or in part, in another
156       publication, requires the prior written consent from an authorized
157       representative of MySQL AB. MySQL AB reserves any and all rights to
158       this documentation not expressly granted above.
159
160       Please email <docs@mysql.com> for more information.
161

SEE ALSO

163       For more information, please refer to the MySQL Reference Manual, which
164       may already be installed locally and which is also available online at
165       http://dev.mysql.com/doc/.
166

AUTHOR

168       MySQL AB (http://www.mysql.com/).  This software comes with no
169       warranty.
170
171
172
173MySQL 5.0                         07/04/2007                      MYSQLSHOW(1)
Impressum