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: Question about DBMS_STATS and Histograms

Re: Question about DBMS_STATS and Histograms

From: Jusung Yang <JusungYang_at_yahoo.com>
Date: 7 May 2003 12:46:10 -0700
Message-ID: <130ba93a.0305071146.2652dca5@posting.google.com>


rgaffuri_at_cox.net (Ryan Gaffuri) wrote in message news:<1efdad5b.0305060637.1334f3ca_at_posting.google.com>...
> I checked on Asktom and I understand how histograms work and what they
> are from college level statistics. However, Im having trouble
> calculating my 'N' buckets. Anyone have a short and dirty method for
> estimating this or a link to one? Couldn't find any general rules of
> thumb on Asktom.
>
> Ryan

I doubt that there is an easy mean of dertermining the optimal bucket size. ORACLE would have done it for you, I would think, if such mean exists. It takes expementations - ORACLE's own DOC says so. You want "enough" buckets to capture the distribution of the data accurately, but on the other hand, you don't want to create too many buckets as they add overhead. Best thing you can hope for seems to be that there are not too many distinct values in your table. If you create more buckets than the number of distinct values in the columns in question, value-balanced histograms will be created. In this case, relatively few buckets will have been created and the selectivity of each and every value can be precisely determined for the optimiser to take advantage of.

Received on Wed May 07 2003 - 14:46:10 CDT

Original text of this message

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