Note
This view is introduced since OceanBase Database V4.0.0.
Purpose
The DBA_OB_TABLEGROUP_TABLES view displays associations between table groups and tables in the current tenant. Tables that do not belong to a table group are not displayed.
Columns
| Column | Type | Nullable? | Description |
|---|---|---|---|
| TableGROUP_NAME | VARCHAR2(128) | NO | The name of the table group. |
| OWNER | VARCHAR2(128) | NO | The name of the database where the table belongs. |
| TABLE_NAME | VARCHAR2(256) | NO | The name of the table. |
| SHARDING | VARCHAR2(10) | NO | The SHARDING attribute of the table group. Valid values:
|
Sample query
A user tenant queries the associations of the table group named TBLGROUP1 in the current tenant.
obclient [SYS]> SELECT * FROM SYS.DBA_OB_TABLEGROUP_TABLES WHERE tablegroup_name = 'TBLGROUP1';
The query result is as follows:
+-----------------+-------+------------+----------+
| TABLEGROUP_NAME | OWNER | TABLE_NAME | SHARDING |
+-----------------+-------+------------+----------+
| TBLGROUP1 | SYS | TBL3 | NONE |
+-----------------+-------+------------+----------+
1 row in set