[oracle-l] Re: Index block count

  • From: Carel-Jan Engel <cjpengel.dbalert@xxxxxxxxx>
  • To: oracle-l@xxxxxxxxxxxxx
  • Date: Tue, 27 Jan 2004 21:22:36 +0200

Tom,
Maybe you've gone through this already, but I would like you to ask why you 
run the query 8.000 times, and during what period of time. 8.000 times in a 
week isn't much, 8000 times in a function in a loop is a serious candidate 
for optimization.

"Tune the question, not the query" Tom Kyte said in Copenhagen. So, back to 
square one. What is the problem you want to solve using thes 8000 queries? 
Is there a better approach possible? I hate to talk in quotes only, but 
there are a couple of clever guys out there pointing things out very clear: 
"The best way to optimize things is stop ding it!" (Cary Millsap). Is there 
a way to do these 8000 queries thing in a single SQL?

This is not an answer to your question, I apologize. Sir Jonathan can 
explain that far better than I can.

Regards, Carel-Jan Engel

===
If you think education is expensive, try ignorance. (Derek Bok)
===

At 11:08 PM 1/27/2004, you wrote:
>I have a b-tree, unique, local, prefixed, range partitioned index.  The blevel
>on all of the partitions is 2.  There are no chained/migrated rows in the 
>table.
>
>I have a query that selects 1 record and only uses the index.  I am not 
>sure why
>the query uses 4 blocks.  I would think that it would just have to use 1 
>for the
>branch block and 1 for the leaf block.  Can someone explain it to me?  (I have
>run the query 8,000 times and the average blocks per execution is 4.1)
>Thanks,
>Tom
>
>-------------------------------------------------------------
>Please see the official ORACLE-L FAQ: http://www.orafaq.com
>-------------------------------------------------------------
>To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx
>put 'unsubscribe' in the subject line.
>-------------------------------------------------------------


-------------------------------------------------------------
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-------------------------------------------------------------
To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx
put 'unsubscribe' in the subject line.
-------------------------------------------------------------

Other related posts: