Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

"alter table truncate partition" marks UNUSABLE all local indexes?

AndrewGoodnightDec 11 2010 — edited Apr 4 2012
Hi all,
here is an excerpt from [Oracle Database SQL Reference10g Release 2|http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/statements_3001.htm#i2149942] (http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/statements_3001.htm#i2149942)

update_global_index_clause

Use this clause to update only global indexes on table. Oracle Database marks UNUSABLE all local indexes on table.

however, after i issued the following alter table command:
alter table myTable truncate partition P1 update global indexes;

i then checked the local indexes on my table with this query:
select t.status, t.partition_name, t.*
from all_ind_partitions t
where t.partition_name = 'P1'
and t.index_name in (select index_name
from all_part_indexes t
where t.locality = 'LOCAL')
;
it turned out the statuses were all USABLE.

am i missing anything?

TIA
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 2 2012
Added on Dec 11 2010
5 comments
12,880 views