Note
This view is introduced since OceanBase Database V1.4.
Purpose
The V$SESSTAT view displays the session-level statistics about the current OBServer node.
Note that STATISTIC# indicates the number of a statistical item. You can query the V$STATNAME view for the name and description of a statistical item based on its number.
Columns
| Column | Type | Nullable? | Description |
|---|---|---|---|
| SID | NUMBER | NO | For V4.3.x:
|
| CON_ID | NUMBER | NO | The ID of the tenant. |
| SVR_IP | VARCHAR2(46) | NO | The IP address of the OBServer node. |
| SVR_PORT | NUMBER(38) | NO | The port number of the OBServer node. |
| STATISTIC# | NUMBER | NO | The number of the statistical item. |
| VALUE | NUMBER | NO | The value of the statistical item. |
Sample query
Query session-level statistics.
obclient [SYS]> SELECT * FROM SYS.V$SESSTAT WHERE ROWNUM =1\G
The query result is as follows:
*************************** 1. row ***************************
SID: 1152921504606867748
CON_ID: 1004
SVR_IP: xx.xx.xx.xx
SVR_PORT: 2882
STATISTIC#: 0
VALUE: 0