Home » SQL & PL/SQL » SQL & PL/SQL » Display in rows
Display in rows [message #19367] Wed, 13 March 2002 03:21 Go to next message
Jan muis
Messages: 1
Registered: March 2002
Junior Member
Hi,

I have a little problem.
Is it possible to display something like:

jan jan jan jan

in stead of

jan
jan
jan
jan

These are four different table values ;)
Please help me!!

Greetz,

Jan
Re: Display in rows [message #19368 is a reply to message #19367] Wed, 13 March 2002 04:00 Go to previous message
Jon
Messages: 483
Registered: May 2001
Senior Member
This is not easily done in SQL, but is done fairly easily in PL/SQL:

08:58:14 ==> declare
08:58:14 2 cursor c1 is select col1 from table1;
08:58:14 3 begin
08:58:14 4 for crec in c1
08:58:14 5 loop
08:58:14 6 dbms_output.put(crec.col1||' ');
08:58:14 7 end loop;
08:58:14 8 dbms_output.put_line(' ');
08:58:14 9 end;
08:58:14 10 /
Jan Jan Jan Jan Jan

PL/SQL procedure successfully completed.
Previous Topic: pl/sql stored procedure
Next Topic: Re: Oracle 7.3 Installation
Goto Forum:
  


Current Time: Fri Mar 29 08:33:54 CDT 2024