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

Home -> Community -> Mailing Lists -> Oracle-L -> Creating Histograms

Creating Histograms

From: Freeman, Donald <dofreeman_at_state.pa.us>
Date: Wed, 21 Jul 2004 14:04:33 -0400
Message-ID: <AFF54B073FF15849B53E32E67EE860763A7D22@ENHBGPRI11.PA.LCL>


I'm trying to improve my knowledge of tuning and the performance of my = 9i Ver 9.2.0.4 data warehouse by creating histograms on columns used in = where clauses with skewed data values. I have extracted the columns = included in where clauses, determined the distinct number of values and = count using a "select distinct (value), count(*), group by statement" = and think I have identified which are some good candidates for = histograms. The documentation and articles about this issue I have read = make it clear that histograms should only be used on columns being used, = having skewed data. However, the dbms_stats.gather_schema_stats = procedure with method_opt seems to create histograms whether the column = is being used or the data is skewed. The 'gather_schema_stats' procedure = is the only one demonstrated and seems to violate the rule. The = 'gather_table_stats" procedure seems like it would give you more = selectivity. I'm having a little trouble with this topic. When I = checked, there are values for all tables in dba_histograms although I = have never run schema_stats with the method_opt set to anything but = default. =20

Am I on the right track here? How do I use this feature without = violating the 'rules?' I'm guessing if I run it and screw up my = performance I can reset my histograms by rerunning dbms_stats with the = default method_opt. Any advice useful or otherwise is welcome.

Thanks,

Don Freeman
Database Administrator 1
Pennsylvania Dept of Health
Bureau of Information Technology



Please see the official ORACLE-L FAQ: http://www.orafaq.com

To unsubscribe send email to: oracle-l-request_at_freelists.org put 'unsubscribe' in the subject line.
--

Archives are at http://www.freelists.org/archives/oracle-l/ FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html
Received on Wed Jul 21 2004 - 13:01:51 CDT

Original text of this message

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