Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: How does DBMS_STATS select columns to generate histograms?
Hi Mladen
>Does anybody know the where clause used to select columns which=20
>will have histograms? Is there a fixed cutoff number =
(EQUALITY_PREDS>x)?
>Percentage?
Honestly I don't know exactly... In any case I have a demo, which I show = when I'm trying to explain how 'SIZE AUTO' works, where a single = statement (i.e. predicate) is enough to lead to the histogram gathering. = I also observed that the timestamp is important, i.e. old entries are = not considered (sorry, I never did extensive tests to find out after how = many days they are no more considered...).=20
Also note that the CBO only increases the counters when a statement is = parsed, i.e. the absolute value is therefore so not important....
Therefore, IMHO, they simply give a look if in the last x days the = column has been used in a predicate.=20
Corrections and addition information is highly welcome!
HTH
Chris
-- http://www.freelists.org/webpage/oracle-lReceived on Tue Mar 22 2005 - 08:16:58 CST