Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Wed, 13 Jan 2010 @ 20:04:40 GMT


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


Subj:   Need SQL help: rollup on column
 
From:   Anomy Anom

<-- Anonymously Posted: Wednesday, January 13, 2010 10:43 -->

Hi All,

I need help regarding a query.

I have a table like below. I need to rollup through column Z and and also to append p2 .

     X                 Y        Z    P2
     -----------------------------------------
     01041708773046    96496    0    A
     01041708773046    96496    1    B
     01041708773046    96496    1    C
     01041708773046    96496    1    D
     01041708773046    96496    2    E
     01041708773046    96496    2    F
     01041708773046    96496    2    G
     01041708773046    96496    3    H

Desired result:

     X                 Y        Z    P2
     -----------------------------------------
     01041708773046    96496    0    A
     01041708773046    96496    1    BCD
     01041708773046    96496    2    EFG
     01041708773046    96496    3    H

Thanks in advance.



     
  <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