Overview
Displays information about all index subpartitions in the database.
Columns
Field Name |
Type |
Whether can be NULL |
Description |
|---|---|---|---|
| INDEX_OWNER | varchar(128) | NO | Owner of the index |
| INDEX_NAME | varchar(128) | NO | Index Name |
| TABLE_NAME | varchar(128) | NO | Table name of the index |
| PARTITION_NAME | varchar(128) | NO | Partition name |
| SUBPARTITION_NAME | varchar(128) | NO | Subpartition name |
| HIGH_VALUE | mediumtext | NO | Expression for Binding Values to Subpartitions |
| HIGH_VALUE_LENGTH | bigint(20) | NO | Length of Value Expression Bound to Subpartition |
| PARTITION_POSITION | bigint(20) | NO | Partition location in the index |
| SUBPARTITION_POSITION | bigint(20) | NO | Location of Subpartition in Partition |
| STATUS | varchar(8) | NO | Indicates whether the index partition is available. |
| TABLESPACE_NAME | varchar(30) | NO | Name of the tablespace containing the partition |
| PCT_FREE | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| INI_TRANS | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| MAX_TRANS | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| INITIAL_EXTENT | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| NEXT_EXTENT | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| MIN_EXTENT | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| MAX_EXTENT | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| MAX_SIZE | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| PCT_INCREASE | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| FREELISTS | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| FREELIST_GROUPS | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| LOGGING | varchar(3) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| COMPRESSION | varchar(13) | NO | Specifies whether compression is enabled for the partitioned index. Valid values:
|
| BLEVEL | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| LEAF_BLOCKS | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| DISTINCT_KEYS | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| AVG_LEAF_BLOCKS_PER_KEY | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| AVG_DATA_BLOCKS_PER_KEY | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| CLUSTERING_FACTOR | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| NUM_ROWS | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| SAMPLE_SIZE | bigint(0) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| LAST_ANALYZED | date | NO | This field is not supported. Currently, the default value of this field is NULL. |
| BUFFER_POOL | varchar(7) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| FLASH_CACHE | varchar(7) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| CELL_FLASH_CACHE | varchar(7) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| USER_STATS | varchar(3) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| GLOBAL_STATS | varchar(3) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| INTERVAL | varchar(3) | NO | This field is not supported. Currently, the default value of this field is NO |
| SEGMENT_CREATED | varchar(3) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| DOMIDX_OPSTATUS | varchar(6) | NO | This field is not supported. Currently, the default value of this field is NULL. |
| PARAMETERS | text | NO | This field is not supported. Currently, the default value of this field is NULL. |
Sample query
The user tenant queries the index subpartition (secondary partition) information in the index table tbl2_f_rl of its own tenant.
obclient [infotest]> SELECT INDEX_OWNER, INDEX_NAME, PARTITION_NAME, SUBPARTITION_NAME, HIGH_VALUE, HIGH_VALUE_LENGTH, PARTITION_POSITION, SUBPARTITION_POSITION FROM oceanbase.DBA_IND_SUBPARTITIONS WHERE TABLE_NAME='tbl2_f_rl';
The query result is as follows:
+-------------+----------------+----------------+-------------------+------------+-------------------+--------------------+-----------------------+
| INDEX_OWNER | INDEX_NAME | PARTITION_NAME | SUBPARTITION_NAME | HIGH_VALUE | HIGH_VALUE_LENGTH | PARTITION_POSITION | SUBPARTITION_POSITION |
+-------------+----------------+----------------+-------------------+------------+-------------------+--------------------+-----------------------+
| infotest | tbl2_f_rl_idx1 | p1 | sp3 | 1,3 | 3 | 2 | 1 |
| infotest | tbl2_f_rl_idx1 | p1 | sp4 | 4,6 | 3 | 2 | 2 |
| infotest | tbl2_f_rl_idx1 | p1 | sp5 | 7,9 | 3 | 2 | 3 |
| infotest | tbl2_f_rl_idx1 | p0 | sp0 | 1,3 | 3 | 1 | 1 |
| infotest | tbl2_f_rl_idx1 | p0 | sp1 | 4,6 | 3 | 1 | 2 |
| infotest | tbl2_f_rl_idx1 | p0 | sp2 | 7,9 | 3 | 1 | 3 |
+-------------+----------------+----------------+-------------------+------------+-------------------+--------------------+-----------------------+
6 rows in set