Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: SELECT statement efficiency question
Mladen Gogala schrieb:
> On Sun, 08 Apr 2007 06:37:37 -0700, Charles Hooper wrote:
>
>> Good advice given so far. I would caution against creating too many >> indexes, as this will likely negatively impact performance of other >> parts of the system
I think, the increased IO activity is negligible compared to increased
latch contention in this case.
Here was an interesting blog entry about this
http://esemrick.blogspot.com/2006/03/unused-indexes-and-scalability.html
One can simply run this test to see the difference in 'cache buffers
chains' latches:
create table d as select * from dba_objects where 1=2;
create table d1 as select * from dba_objects where 1=2;
spool d.sql
select 'CREATE INDEX D_'||COLUMN_ID||' ON D('||COLUMN_NAME||');' from
dba_tab_columns where table_name = 'DBA_OBJECTS'
spool off
@d
exec runstats_pkg.rs_start
insert into d1 select * from dba_objects;
exec runstats_pkg.rs_middle
insert into d select * from dba_objects;
exec runstats_pkg.rs_stop
To be consequent, one should run 10046 trace for the indexed case and compare time spent due to IO related wait events and latch related wait events...
Some years ago i've to do a big data load into OLTP Siebel system over weekend - some of very important tables (like s_customer) here often have about 40-50 indexes per table (they are just illdesigned so, to be generic) . The only possibility to get it done was to drop all indexes not required for load and recreate them after it. I suppose, many ERP systems don't differ much in this regard from Siebel.
Best regards
Maxim Received on Sun Apr 08 2007 - 13:15:42 CDT
![]() |
![]() |