Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Tue, 21 Jun 2011 @ 12:32:47 GMT


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


Subj:   Re: Distinct vs. group by in TD 13 onwards
 
From:   Fenwick, Ruth

For those already on TD13, would someone check:

Are both DISTINCT and GROUP BY single amp for the following type of query:

     SELECT COL1, COL2, COL3 FROM TABLE WHERE PRIMARY INDEX = 123 GROUP BY 1,2,3
     ; SELECT DISTINCT COL1, COL2, COL3 FROM TABLE WHERE PRIMARY INDEX = 123;

For TD12 and below, a DISTINCT is single amp, GROUP BY is all AMP. We have 'faked out' the optimizer, by having tactical applications always code DISTINCT.


Ruth



     
  <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