what is spool?
stores query results in a file,or optinally send the file to printer.
cmd>prompt or create file as .bat file
c:\spool/spool.bat
echo off
@echo "##########SPOOL ##################"
sqlplus scott/tiger@omkara @C:\spool\spool.SQL
@echo on;
PAUSE
Exit;
C:\spool\spool.SQL
set pagesize 1000;
set linesize 1000;
spool C:\spool\spool.txt --data spool into the spool.txt file automatically
select *from emp;
spool off;
quit
/
No comments:
Post a Comment