Overview
The system tenant displays the tablet list for all tenants and the log stream information to which each tablet belongs.
Columns
Field Name |
Type |
Whether can be NULL |
Description |
|---|---|---|---|
| TENANT_ID | bigint(20) | NO | Tenant ID |
| TABLET_ID | bigint(20) | NO | TABLET ID |
| LS_ID | bigint(1) | NO | Log stream ID of the tablet |
Sample query
The system tenant queries the tablet list information of log stream 1001 for tenant with ID 1002 and displays the first five entries.
obclient [oceanbase]> SELECT * FROM oceanbase.CDB_OB_TABLET_TO_LS WHERE TENANT_ID=1002 AND LS_ID=1001 LIMIT 5;
The query result is as follows:
+-----------+-----------+-------+
| TENANT_ID | TABLET_ID | LS_ID |
+-----------+-----------+-------+
| 1002 | 200004 | 1001 |
| 1002 | 200005 | 1001 |
| 1002 | 200007 | 1001 |
| 1002 | 200008 | 1001 |
| 1002 | 200009 | 1001 |
+-----------+-----------+-------+
5 rows in set