rebuild partition index
650105Jun 25 2009 — edited Jun 29 2009hello
i have unusable a index. Now i want to rebuild index for this i have to rebuild partition and tablespace in two different command like
ALTER INDEX index_name REBUILD PARTITION p1;
ALTER INDEX index_name REBUILD PARTITION p1 TABLESPACE INDX_TS;
now my question is when i run first command and check status fof index it show usable. Similarly when i ran only 2nd command also rebuild successfully. if i ran only 2nd command work fine?
why it show usable after only rebuild partition?
i have generate script for all user indexes like this
Select 'ALTER INDEX '|| index_name ||' rebuild partition ' || PARTITION_NAME ||';' from USER_IND_PARTITIONS
Select 'ALTER INDEX '|| index_name ||' rebuild partition ' || PARTITION_NAME || ' TABLESPACE ' || tablespace_name ||';' from USER_IND_PARTITIONS