All pages
Powered by GitBook
1 of 1

Loading...

SHOW USER_STATISTICS

View statistics on user activity. This statement displays metrics like CPU time and rows read for each user account.

Syntax

SHOW USER_STATISTICS

Description

The SHOW USER_STATISTICS statement is part of the feature. It was effectively replaced by the generic statement. The table holds statistics about user activity. You can use this table to find out such things as which user is causing the most load and which users are being abusive. You can also use this table to measure how close to capacity the server may be.

The SHOW USER_STATISTICS statement is part of the feature. The table holds statistics about user activity. You can use this table to find out such things as which user is causing the most load and which users are being abusive. You can also use this table to measure how close to capacity the server may be.

The system variable must be set to 1 to activate this feature. See the and table for more information.

Example

This page is licensed: CC BY-SA / Gnu FDL

User Statistics
information_schema.USER_STATISTICS
User Statistics
information_schema.USER_STATISTICS
userstat
User Statistics
information_schema.USER_STATISTICS
SHOW USER_STATISTICS\G
*************************** 1. row ***************************
                  User: root
     Total_connections: 1
Concurrent_connections: 0
        Connected_time: 3297
             Busy_time: 0.14113400000000006
              Cpu_time: 0.017637000000000003
        Bytes_received: 969
            Bytes_sent: 22355
  Binlog_bytes_written: 0
             Rows_read: 10
             Rows_sent: 67
          Rows_deleted: 0
         Rows_inserted: 0
          Rows_updated: 0
       Select_commands: 7
       Update_commands: 0
        Other_commands: 0
   Commit_transactions: 1
 Rollback_transactions: 0
    Denied_connections: 0
      Lost_connections: 0
         Access_denied: 0
         Empty_queries: 7
SHOW information_schema_table