Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Tue, 20 Jun 2006 @ 20:29:56 GMT


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


Subj:   Re: Update stament gives a multiple source rows error
 
From:   Bhattiprolu, Phaneendra

You can update the same target row with multiple source rows. This leads to ambiguity in deciding which one to use to update.

You can have something like this:

     UPDATE TAB1 FROM
     (SELECT max(CNAME) cmax
     FROM TAB2 b
     WHERE b.COL1 = TAB1.COL1) VAL
     SET  COL2=VAL.CMAX;


     
  <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