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!

DISABLE DROP or UNUSABLE of index to speed up inserts?

537177May 8 2007 — edited May 8 2007
Hi,

I am inserting about 10 millions rows into a table, wich having 3 types of indexes :
functioanal base, bitmap and normal.

Now to speed up the insert I am thinkig of disabling the indexes, but not really sure which
solution would be better:

Solution 1:
- disable indexes
- INSERT
- enable indexes
- dbms_stats.gather_index_stats(...

Solution 2:
- drop indexes
- INSERT
- CREATE INDEX...
- dbms_stats.gather_index_stats();

Solution 3:

- ALTER INDEX <index_name> UNUSABLE;
- INSERT
- ALTER INDEX bix_gender REBUILD;
- dbms_stats.gather_index_stats();

One more thing...

Is this correct, that DISABLE applies to a function-based index only???

Thanks!!!
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 5 2007
Added on May 8 2007
7 comments
37,930 views