Rebuild an Index Partition

Rebuild an Index Partition example In oracle database to rebuild an index partition you must use the command alter index with REBUILD PARTITION keyword. — create Range-Partitioned Global Index CREATE INDEX amount_idx ON orders (amount) GLOBAL PARTITION BY RANGE (amount) (PARTITION part_1 VALUES LESS THAN (1000), PARTITION part_2 VALUES LESS THAN (2000), PARTITION part_3 VALUES…(Continue Reading)

Set Index Parallel

Set Index Parallel example In Oracle database to set an index parallel you must use the command alter index with REBUILD PARALLEL keyword. — set Index Parallel ALTER INDEX STU_LN_IDX REBUILD PARALLEL; Output: index STU_LN_IDX altered. Check indexes select INDEX_NAME, DEGREE, INSTANCES from USER_INDEXES WHERE TABLE_NAME=’STUDENTS_LIST’; Output: INDEX_NAME DEGREE INSTANCES STUDENT_IDX 1 1 STU_LN_IDX DEFAULT…(Continue Reading)

Collect Index Statistics

Collect Index Statistics example In Oracle database to collect an index statistics you must use the command alter index with REBUILD COMPUTE STATISTICS keyword. — Collect Index Statistics ALTER INDEX STU_LN_IDX REBUILD COMPUTE STATISTICS; Output: index STU_LN_IDX altered.

Enable an Index Partition

Enable an Index Partition example In oracle database to enable an index partition you must use the command alter index with REBUILD PARTITION keyword. — enable Index Partition rebuild ALTER INDEX amount_idx REBUILD PARTITION part_2; Output: index AMOUNT_IDX altered. Check partitions select INDEX_NAME, PARTITION_NAME, STATUS from USER_IND_PARTITIONS WHERE INDEX_NAME=’AMOUNT_IDX’; Output: INDEX_NAME PARTITION_NAME STATUS AMOUNT_IDX PART_1…(Continue Reading)

Disable an Index Partition

Disable an Index Partition example In oracle database to disable an index partition you must use the command alter index with UNUSABLE keyword. — create Range-Partitioned Global Index CREATE INDEX amount_idx ON orders (amount) GLOBAL PARTITION BY RANGE (amount) (PARTITION part_1 VALUES LESS THAN (1000), PARTITION part_2 VALUES LESS THAN (2000), PARTITION part_3 VALUES LESS…(Continue Reading)