Note
This view is available starting with V1.4.
Purpose
This view records server status variables of a session, including the number of active connections and the uptime of the database.
Columns
Column |
Type |
Nullable |
Description |
|---|---|---|---|
| VARIABLE_NAME | varchar(128) | NO | The name of the session status variable. |
| VARIABLE_VALUE | varchar(1024) | YES | The value of the session status variable. |
Sample query
Query the server status variables and their corresponding values of a session.
obclient [oceanbase]> SELECT * FROM information_schema.SESSION_STATUS;
The query result is as follows:
+-------------------+----------------+
| VARIABLE_NAME | VARIABLE_VALUE |
+-------------------+----------------+
| Threads_connected | 2 |
| Uptime | 255239 |
+-------------------+----------------+
2 rows in set
