Note
This view is introduced since OceanBase Database V4.0.0.
Purpose
This view displays the DML information of all user tables in the current tenant across all OBServer nodes.
Columns
| Column | Type | Nullable? | Description |
|---|---|---|---|
| SVR_IP | VARCHAR2(46) | NO | The IP address of the server. |
| SVR_PORT | NUMBER | NO | The port number of the server. |
| INST_ID | NUMBER | NO | The ID of the tenant. |
| OBJN | NUMBER | NO | The ID of the object. |
| INS | NUMBER | NO | The approximate number of insertions since the statistics were last collected. |
| UPD | NUMBER | NO | The approximate number of updates since the statistics were last collected. |
| DEL | NUMBER | NO | The approximate number of deletions since the statistics were last collected. |
| DROPSEG | NUMBER | NO | Not supported. The default value is NULL. |
| CURROWS | NUMBER | NO | Not supported. The default value is NULL. |
| PAROBJN | NUMBER | NO | Not supported. The default value is NULL. |
| LASTUSED | NUMBER | NO | Not supported. The default value is NULL. |
| FLAGS | NUMBER | NO | Not supported. The default value is NULL. |
| CON_ID | NUMBER | NO | Not supported. The default value is NULL. |
Sample query
View the DML information of user tables in this tenant on all OBServer nodes.
obclient [SYS]> SELECT * FROM SYS.GV$DML_STATS;
The query result is as follows:
+----------------+----------+---------+--------+------+------+------+---------+---------+---------+----------+-------+--------+
| SVR_IP | SVR_PORT | INST_ID | OBJN | INS | UPD | DEL | DROPSEG | CURROWS | PAROBJN | LASTUSED | FLAGS | CON_ID |
+----------------+----------+---------+--------+------+------+------+---------+---------+---------+----------+-------+--------+
| 11.xxx.xxx.xxx | 28825 | 1004 | 1 | 0 | 54 | 0 | NULL | NULL | 1 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 331 | 7 | 0 | 8 | NULL | NULL | 331 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 377 | 0 | 136 | 0 | NULL | NULL | 377 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 519 | 69 | 0 | 0 | NULL | NULL | 519 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 101105 | 69 | 0 | 0 | NULL | NULL | 101105 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 101106 | 69 | 0 | 0 | NULL | NULL | 101106 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 150 | 0 | NULL | NULL | 200002 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 150 | 0 | NULL | NULL | 200003 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 100 | 0 | NULL | NULL | 200004 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 100 | 0 | NULL | NULL | 200005 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 90 | 0 | NULL | NULL | 200006 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 90 | 0 | NULL | NULL | 200007 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 60 | 0 | NULL | NULL | 200008 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 60 | 0 | NULL | NULL | 200009 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 60 | 0 | NULL | NULL | 200010 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 60 | 0 | NULL | NULL | 200011 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 40 | 0 | NULL | NULL | 200012 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500003 | 0 | 40 | 0 | NULL | NULL | 200013 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500019 | 68 | 0 | 0 | NULL | NULL | 200014 | NULL | NULL | NULL |
+----------------+----------+---------+--------+------+------+------+---------+---------+---------+----------+-------+--------+
19 rows in set