SQL statement question ........

From: Jimmy <c6635500_at_comp.polyu.edu.hk>
Date: Sat, 12 Jun 1999 21:27:38 -0700
Message-ID: <3763333A.3F096431_at_comp.polyu.edu.hk>



[Quoted] Hello all,

[Quoted]     I have a table aaa as follows:

create table T_aa (
aaa date,
bbb varchar2(10),
[Quoted] ccc number);

[Quoted] [Quoted] And I want to get the following result with SQL select statement:

a_date, bbb, ccc
01-Jan-1999,50,1
02-Jan-1999,,1
03-Jan-1999,70,2

(column aaa renamed to a_date)

And I write the following SQL statement:

select to_char(aaa, 'DD-MON-YYYY') a_date || ',' || bbb || ',' ||ccc from T_aa;

however, the above statement is invalid. Is is possible to get the result that I want by using a single SQL statement?

Thanks,
Jimmy Received on Sun Jun 13 1999 - 06:27:38 CEST

Original text of this message