Home » SQL & PL/SQL » SQL & PL/SQL » Spooling
Spooling [message #39368] Thu, 11 July 2002 21:20 Go to next message
Mahesh
Messages: 90
Registered: January 2001
Member
Hi,

I have a sql not a stored procedure. In this sql we query on few tables (i use cursors and fetch loop )
After some processing in display the variables using
select var1,var2.. from dual;

I use the lst file(spool output) for processing by C program.

eg:

set tab off
set hea off
spool filename
declare
cursor....

begin

cursor processing in fetch loop

...
...
select var1,var2,var3 from dual;

end;

this doesn't work. so tell me how i can proceed becuase i can't take the column names directly.

thanks in advance
Re: Spooling [message #39371 is a reply to message #39368] Fri, 12 July 2002 03:52 Go to previous message
Hari Babu
Messages: 2
Registered: July 2002
Junior Member
Hi Mahesh,

You can use the below SQL:
See the below query and its result:
SQL> select 'var' var,'var1' var1 from dual;

VAR VAR1
--- ----
var var1

Hope this solves ur problem...

Thanks,
Hari
Previous Topic: South African Time
Next Topic: Problem with REF CURSOR and Synonyms
Goto Forum:
  


Current Time: Tue Jul 16 03:02:08 CDT 2019