Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Thu, 13 Mar 2003 @ 08:49:48 GMT


     
  <Prev Next>   <<First <Prev Next> Last>>  


Subj:   Re: Stats on the PI
 
From:   Dieter N�th

Anomy Anom wrote:

  I have read that you should collect stats on the PI of only small tables. Why only small tables? Does it hurt to collect stats on the PI of a large table?  


If it's a UPI the optimizer already knows about the cardinality (maximum number of rows/value = 1), so if you don't use e.g. BETWEEN you don't need statistics. Collecting stats on a large table needs a long time. This is much better now in V2R5, because you can collect on a sample.


  Also someone said "If you don't have stats on the PI of a table then the optimiser will ignore any other stats that are collected on the table." If that is true and you are not suppose to collect stats on the PI of a large table then don't we have a problem here?  


Maybe it was correct in early versions, but definitly not in current versions. If you submit a select * Explain is returning the exact number from non-PI stats, but "with low confidence" ;-)


Dieter



     
  <Prev Next>   <<First <Prev Next> Last>>  
 
 
 
 
 
 
 
 
  
  Top Home Privacy Feedback  
 
 
Copyright for the TeradataForum (TDATA-L), Manta BlueSky    
Copyright 2016 - All Rights Reserved    
Last Modified: 15 Jun 2023