I want Oracle Query for Formatted Output

Posted by reply2viveksshah on Stack Overflow See other posts from Stack Overflow or by reply2viveksshah
Published on 2010-05-21T03:50:16Z Indexed on 2010/05/22 1:30 UTC
Read the original article Hit count: 310

Filed under:
|

The following is my table design:

Ecode           Degree              YOQ
7654321         SSC                 2000
7654321         HSC                 2002
7654321         Bcom                2006
7654321         MCA                 2010
7654322         SSC                 2002
7654322         HSC                 2004
7654322         Bcom                2007
7654323         SSC                 2002
7654323         HSC                 2004
7654323         BE                  2008

I want the following formatted output using an oracle query:

Ecode        Degree                           year
7654321      SSC,HSC,Bcom,MCA                 2000,2002,2006,2010          
7654322      SSC,HSC,Bcom                     2002,2004,2007
7654323      SSC,HSC,BE                       2002,2004,2008

How can this be done?

© Stack Overflow or respective owner

Related posts about Oracle

Related posts about query