Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: using "alter index xxx unusable"
"Jonathan Lewis" <jonathan_at_jlcomp.demon.co.uk> wrote in
news:dnmnqr$lhu$1_at_nwrdmz03.dmz.ncs.ea.ibs-infra.bt.com:
> "Michael Peel" <peelm_at_NOSPAMaccuread.com> wrote in message > news:Xns972B925A72A1BpeelmNOSPAMaccureadc_at_194.6.79.66...
> > > This behaviour is a little surprising, but totally normal. > As you truncate a table, you automatically truncate > all the indexes . So the indexes are suddenly self-consistent > again which makes the indexes usable again. (Oracle is > not aware of the fact that you might really want them to > be unusable - normally it's an unfortunate accident). > > However, you probably don't need to set the indexes > unusable to benefit from the insert /*+ append */, as > the indexes are maintained with an array insert after the > insert is complete. (There are some funny side-issues > with enabled foreign key constraints, though, but too > many if/then/buts to put into a short note). >
Jonathan,
Thanks for the speedy response…
Makes sense.
I’ll do some benchmarking around marking the indexes as unsable, and not. I was getting fairly large redo with the insert and the indexes in tact, but I guess this redo is now associated with the index rebuild. I’ll mark the build as nologging and see what happens.
Thanks again.
M. Received on Tue Dec 13 2005 - 09:14:30 CST
![]() |
![]() |