Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Query Generating Horizontal Totals

Query Generating Horizontal Totals

From: tranvirus <claudio_at_santana.net>
Date: 4 Feb 2004 14:01:27 -0800
Message-ID: <39bc48bc.0402041401.4dbe6a12@posting.google.com>


Hi all,

I have this table:

Col1    Col2     Col3
A        A1        5
A        A2        3
A        A3        2
A        A4        4
B        B1        6
B        B3        8
B        B4        1
C        C1        3
C        C2        5
C        C3        8
C        C4        2


I want to obtain this from my query:

Col1 Col2 Col3 Col4 Col5

A       5    3    2    4
B       6    0    8    1
C       3    5    8    2

I guess there shuld be a way of doing this kind of operation in Oracle 9i but I don't find the right SQL query. All the help will be appreciated.

Claudio Santana. Received on Wed Feb 04 2004 - 16:01:27 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US