Note
This view is introduced since OceanBase Database V4.0.0.
Purpose
This view displays the DML information of user tables of all tenants on the current OBServer node.
Columns
| Column | Type | Nullable? | Description |
|---|---|---|---|
| SVR_IP | varchar(46) | NO | The IP address of the server. |
| SVR_PORT | bigint(20) | NO | The port number of the server. |
| INST_ID | bigint(20) | NO | The tenant ID. |
| OBJN | bigint(20) | NO | The object ID. |
| INS | bigint(20) | NO | The approximate number of insertions since the statistics were last collected. |
| UPD | bigint(20) | NO | The approximate number of updates since the statistics were last collected. |
| DEL | bigint(20) | NO | The approximate number of deletions since the statistics were last collected. |
| DROPSEG | bigint(0) | NO | Not supported. The default value is NULL. |
| CURROWS | bigint(0) | NO | Not supported. The default value is NULL. |
| PAROBJN | bigint(20) | NO | Not supported. The default value is NULL. |
| LASTUSED | bigint(0) | NO | Not supported. The default value is NULL. |
| FLAGS | bigint(0) | NO | Not supported. The default value is NULL. |
| CON_ID | bigint(0) | NO | Not supported. The default value is NULL. |
Sample query
View the DML information of the user table in the current OBServer node for the tenant with the tenant ID of 1004.
obclient [oceanbase]> SELECT * FROM oceanbase.V$DML_STATS WHERE INST_ID=1004;
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 | 10 | 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 | 26 | 0 | NULL | NULL | 377 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 519 | 14 | 0 | 0 | NULL | NULL | 519 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 101105 | 14 | 0 | 0 | NULL | NULL | 101105 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 101106 | 14 | 0 | 0 | NULL | NULL | 101106 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500019 | 13 | 0 | 0 | NULL | NULL | 200014 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 1 | 0 | 10 | 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 | 26 | 0 | NULL | NULL | 377 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 519 | 14 | 0 | 0 | NULL | NULL | 519 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 101105 | 14 | 0 | 0 | NULL | NULL | 101105 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 101106 | 14 | 0 | 0 | NULL | NULL | 101106 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500019 | 13 | 0 | 0 | NULL | NULL | 200014 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 1 | 0 | 10 | 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 | 26 | 0 | NULL | NULL | 377 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 519 | 14 | 0 | 0 | NULL | NULL | 519 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 101105 | 14 | 0 | 0 | NULL | NULL | 101105 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 101106 | 14 | 0 | 0 | NULL | NULL | 101106 | NULL | NULL | NULL |
| 11.xxx.xxx.xxx | 28825 | 1004 | 500019 | 13 | 0 | 0 | NULL | NULL | 200014 | NULL | NULL | NULL |
+----------------+----------+---------+--------+------+------+------+---------+---------+---------+----------+-------+--------+
21 rows in set