Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: how to force an index range scan?

Re: how to force an index range scan?

From: Jonathan Lewis <jonathan_at_jlcomp.demon.co.uk>
Date: Sun, 24 Sep 2000 10:27:48 +0100
Message-ID: <969788505.18735.2.nnrp-07.9e984b29@news.demon.co.uk>

When creating histograms, you do need to know a bit about the data to decide on the bucket count. There is a good reason for Oracle's default bucket count being 75 - anything much lower, and you generating statistics with little value. Unless 99% of the data fall into 19 of your 20 buckets, the buckets add little value to the column level stats.

If you post bucket number and end-count for the histogram along with the total row-count, min, max, distinct value and number of nulls of the column and the value you were after, I'll see if I can justify Oracle's 'error' for you.

--

Jonathan Lewis
Yet another Oracle-related web site:  http://www.jlcomp.demon.co.uk

gdas_at_my-deja.com wrote in message <8qgecl$nrt$1_at_nnrp1.deja.com>...

>Sorry for so many posts here. But I seem to have found the problem.
>Don't quite understand it, but it will do for now.
>
>I was analyzing the f_misc table sampling 20 percent and creating a 20
>bucket histogram on all indexed columns. When I removed the histogram,
>I got my index range scan. I tried it with different predicate values
>for account_id and they all come back fast. Very strange. I knew
>histograms don't always help, I guess they can in fact hurt you
>sometimes as well.
>
>Thanks for your time.
>Gavin
>
>
>
>Sent via Deja.com http://www.deja.com/
>Before you buy.
Received on Sun Sep 24 2000 - 04:27:48 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US