SHOW STATUS

SHOW STATUS

SHOW STATUS

Syntax:

SHOW [GLOBAL | SESSION] STATUS [LIKE ‘pattern’]

SHOW STATUS provides server status information. This information also can be obtained using the mysqladmin extended-status command.
With a LIKE clause, the statement displays only rows for those variables with names that match the pattern:

Example:

SHOW STATUS LIKE ‘open%’;

+—————+——-+
| Variable_name | Value  |
+—————+——-+
| Open_files       | 374   |
| Open_streams | 0       |
| Open_tables    | 298   |
| Opened_tables | 0      |
+—————+——-+

4 rows in set (0.00 sec)

The GLOBAL and SESSION options are new in MySQL 5.0.2. With the GLOBAL modifier, SHOW STATUS displays the status values

for all connections to MySQL. With SESSION, it displays the status values for the current connection. If no modifier is present, the default is SESSION. LOCAL is
a synonym for SESSION.

Some status variables have only a global value. For these, you get the same value for both GLOBAL and SESSION.

Leave a Reply

You must be logged in to post a comment.


All material @ copyrighted by chrisranjana.com. If you want to link to this article you are welcome to do so. Unauthorized publication is strictly prohibited. This developer tutorial website contains articles by Php programmers , Software developers, Mysql programmers and asp c# programmers. This website also contains ajax tutorials and advanced mysql sql stored procedures and functions tutorials and sample codes.