histogram oddity: Height-balanced histograms where NDV < num_buckets

  • From: "Charles Schultz" <sacrophyte@xxxxxxxxx>
  • To: oracle-l <oracle-l@xxxxxxxxxxxxx>
  • Date: Fri, 11 Aug 2006 09:59:09 -0500

Oracle 10.2.0.2, Solaris 8

Wondering if anyone could explain this. We have 105 SYS-owned tables where
num_distinct < num_buckets according to dba_tab_col_statistics (see
following query). Even weirder, some columns have 217 buckets for only 1
distinct value (verified in dba_tab_histograms). What kind of sense does
that make? Similarly, we have one application partition that exhibits the
same symptom.

select distinct table_name, column_name, num_distinct, num_buckets
from dba_tab_col_statistics where histogram = 'HEIGHT BALANCED' and
num_distinct < num_buckets
order by num_distinct,num_buckets
/

-mystified

--
Charles Schultz

Other related posts: