Home » SQL & PL/SQL » SQL & PL/SQL » spool ?
spool ? [message #235729] Mon, 07 May 2007 15:34 Go to next message
yog_23
Messages: 79
Registered: March 2007
Member
When I am trying to spool an sql statement to a file, it actually spools the SQL statement itself and the entire commands. Need to spool only the o/p of SQL. Is there any command to do this.

e.g.
spool c:\test.txt
select * from table1;
spool off

o/p file looks like below

select * from table1;
1
2
3
spool off

Need to get rid of select statement and spool off command.. ? Any idea?
Re: spool ? [message #235730 is a reply to message #235729] Mon, 07 May 2007 15:36 Go to previous messageGo to next message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
If you put this in a file and execute the file (with start or @ command) then the command is not in the spool (unless you execute "set echo on").
If you execute in interactive mode then the command is in the spool whatever you do.

Regards
Michel
Re: spool ? [message #235737 is a reply to message #235730] Mon, 07 May 2007 15:59 Go to previous message
yog_23
Messages: 79
Registered: March 2007
Member
thank you, that works Smile
Previous Topic: HELP PLZ
Next Topic: ORA-6550 + PLS-00302 (merged)
Goto Forum:
  


Current Time: Sat Dec 03 20:36:56 CST 2016

Total time taken to generate the page: 0.08353 seconds