Home » SQL & PL/SQL » SQL & PL/SQL » spool
spool [message #348795] Wed, 17 September 2008 23:51 Go to next message
panyam
Messages: 146
Registered: May 2008
Senior Member
Hi All,

I tried to spool the o/p of certain sql scripts ,due to some power issues my system went down.Now my question is " what about the output of those sql scripts " as i did not done spool off.
Can i get the output data ??...

SQL>Spool D:\collection.txt

--certain SQL scripts i run
--did not done spool off due to system went off
--Afetr system restart again i done spool off
SQL> spool off
not spooling currently


Regards
Re: spool [message #348803 is a reply to message #348795] Thu, 18 September 2008 00:02 Go to previous messageGo to next message
Littlefoot
Messages: 20888
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Power loss did "spool off" for you, so - when the database got up again - you have connected via SQL*Plus and this (SQL*Plus) instance had no idea about your previous spooling. Therefore, "SPOOL OFF" command had no effect as there was no spooling to be turned off.
Re: spool [message #348809 is a reply to message #348803] Thu, 18 September 2008 00:15 Go to previous messageGo to next message
navneet_sharma
Messages: 70
Registered: September 2008
Location: New Delhi, India
Member
you will get the output of the sql scripts from location where u have spooled which will contain the outputs till the power failure. As explained in earlier post, spool off will not work.
Re: spool [message #348870 is a reply to message #348809] Thu, 18 September 2008 03:23 Go to previous messageGo to next message
panyam
Messages: 146
Registered: May 2008
Senior Member

Hi Sharma ,

"you will get the output of the sql scripts from location where u have spooled which will contain the outputs till the power failure"


how to get that ??..from sql plus ?
Re: spool [message #348871 is a reply to message #348870] Thu, 18 September 2008 03:28 Go to previous messageGo to next message
ThomasG
Messages: 3189
Registered: April 2005
Location: Heilbronn, Germany
Senior Member
Anything that was spooled before the power loss is already in D:\collection.txt

Re: spool [message #348872 is a reply to message #348870] Thu, 18 September 2008 03:29 Go to previous messageGo to next message
navneet_sharma
Messages: 70
Registered: September 2008
Location: New Delhi, India
Member
you must have given the path while spooling. for example

>spool c:\oracle\abc.txt

> select * from dual;
x

now your session ends due to power failure. now either u can direct browse to c:\oracle and find abc.txt .
or from new session u can do
>ed c:\oracle\abc.txt






Re: spool [message #348877 is a reply to message #348872] Thu, 18 September 2008 03:43 Go to previous message
panyam
Messages: 146
Registered: May 2008
Senior Member
Thanks A lot ..Data is there
Previous Topic: need help on multidimentional array access
Next Topic: Help in this SQLl
Goto Forum:
  


Current Time: Fri Dec 02 20:37:45 CST 2016

Total time taken to generate the page: 0.15211 seconds