Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> 10g gather_table_stats + method_opt +histograms
Looking at Cost Based Oracle Fundamentals by Johnathan Lewis, page 454. It discusses how by default in 10g, gather_table_stats will get histograms on all tables.
I verified that was true by looking in dba_tab_histograms.
I also read in MetaLink, that by setting "method_opt => 'FOR ALL COLUMNS SIZE 1", histograms will NOT be created.
While testing, I see that running as I have below, the histograms are still being created. Am I missing something or am I misinformed?
System is Oracle 10.1.0.3, on HP-UX.
exec DBMS_STATS.DELETE_TABLE_STATS('rf','state_table');
select * from dba_tab_histograms where table_name = 'STATE_TABLE'
< no rows returned - as expected >
exec dbms_stats.gather_table_stats ('rf','state_table', method_opt => 'FOR ALL COLUMNS SIZE 1',CASCADE => TRUE);
select * from dba_tab_histograms where table_name = 'STATE_TABLE'
< rows returned - NOT as I expected >
Thanks for any advice
John Fedock
john.fedock [AT] us.kline.com
-- http://www.freelists.org/webpage/oracle-lReceived on Tue Feb 21 2006 - 15:26:15 CST
![]() |
![]() |