1748180 Members
4066 Online
108759 Solutions
New Discussion юеВ

Spool file issue

 
SOLVED
Go to solution
Dave Walley
Frequent Advisor

Spool file issue

Hi.

When spooling a file from within sqlplus, I get the SQL> prompt in the output, how can I avoid this. I would like the result displayed but neither the query nor SQL prompt included.

I get

SQL> query
123
SQL> spool off

I would like

123



Thanks

Dave
why do i do this to myself
5 REPLIES 5
A. Clay Stephenson
Acclaimed Contributor

Re: Spool file issue

set echo off;
set heading off;

and often
set verify off;
is also used.
If it ain't broke, I can fix that.
Nicolas Dumeige
Esteemed Contributor

Re: Spool file issue

Hello,

Add "set feedback off"

Cheers

Nicolas
All different, all Unix
Dave Walley
Frequent Advisor

Re: Spool file issue

I should have mentioned that I have set the following also.

SQL> set termout off
SQL> set feedback off
SQL> set pagesize 0
SQL> set heading off
SQL> set verify off
SQL> set echo off
SQL> set linesize 10
SQL> set trimspool on

It must be something else

Dave
why do i do this to myself
Nicolas Dumeige
Esteemed Contributor
Solution

Re: Spool file issue

Some option only apply when you are calling an SQL script.

sqlplus -s / @script

not
sqlplus << EOF
option
spool
select ...
spool off
EOF

Cheers

Nicolas

All different, all Unix
Arturo Galbiati
Esteemed Contributor

Re: Spool file issue

sqlplus <your sets
@sqlcommandfile.sql
exit
!EOF