RE: Hints

From: MacGregor, Ian A. <ian_at_slac.stanford.edu>
Date: Mon, 15 Aug 2011 10:13:56 -0700
Message-ID: <FD1D618E4F164D4C8BA5513D4268174A015751B1DDD4_at_EXCHCLUSTER1-02.win.slac.stanford.edu>



It may be that Oracle has incorrect statistics concerning your I/O system, or even if those statistics are good, has still misjudged its capabilities. It may be the OS statistics were gathered at an inappropriate time. I am of the opinion that Oracle still overrates full table scans as compared to index lookups. There is an initialization parameter which addresses this.

optimizer_index_cost_adj

I would not change this parameter unless you are sure that the OS statistics were taken under an appropriate load, and the non-optimal FTS choices be made by the optimizer are noticeably slowing the system. Obviously changing the parameter can lead to an index being used when an FTS is optimal.

-----Original Message-----

From: oracle-l-bounce_at_freelists.org [mailto:oracle-l-bounce_at_freelists.org] On Behalf Of Orlando L Sent: Monday, August 15, 2011 9:38 AM
To: Ric Van Dyke
Cc: oracle-l_at_freelists.org
Subject: Re: Hints

Thank you Ric and others.    

I have few queries that run slow, but I have to force them to use indexes. With the use of indexes they run much faster, with statistics present. I am left with the classic question of why is the optimizer not using my indexes and why do I have to force it.          

--

http://www.freelists.org/webpage/oracle-l Received on Mon Aug 15 2011 - 12:13:56 CDT

Original text of this message