Home » SQL & PL/SQL » SQL & PL/SQL » How to generate the spool (.LST) file using PL/SQL?
How to generate the spool (.LST) file using PL/SQL? [message #341710] Wed, 20 August 2008 01:34 Go to next message
fazal_haq2001
Messages: 35
Registered: July 2006
Location: India
Member
Hi friends,
I ve a set of procedures.I ve written set of dbms_output.put_line
codes in it for tracking.
If i run the procedures through SQL, i get it through "set serveroutput on"
But if i run the procedure through oracle forms, I m unable to generate .LST files..
Is there any way to generate spool files through pl/sql..

Regards,
FAZ...
Re: How to generate the spool (.LST) file using PL/SQL? [message #341727 is a reply to message #341710] Wed, 20 August 2008 02:15 Go to previous messageGo to next message
Frank
Messages: 7901
Registered: March 2000
Senior Member
dbms_output.put_line is a lousy way to do structural logging or debugging. It is nice for quick 'n' dirty stuff.
For structural logging use an autonomous transaction that writes to a table. Benefits are that you are not depending on people setting serveroutput on, it works from all tools, you can track the progress during the process, instead of only afterwards, it is not bound to 255 chars per line, it is not bound to 1000000 characters in total (pre 10g).
Re: How to generate the spool (.LST) file using PL/SQL? [message #341775 is a reply to message #341710] Wed, 20 August 2008 05:03 Go to previous messageGo to next message
fazal_haq2001
Messages: 35
Registered: July 2006
Location: India
Member
Hi,
Thank you for your valuable suggestion.I will try to do so.As of now, Is there any way to get the .LST file like i mentioned earlier through pl/sql.
Re: How to generate the spool (.LST) file using PL/SQL? [message #341794 is a reply to message #341775] Wed, 20 August 2008 06:04 Go to previous message
Michel Cadot
Messages: 68737
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
Use UTL_FILE.

Regards
Michel
Previous Topic: How to find High impact sql query in terms of CPU utilization
Next Topic: How to throw out a "set' of data?
Goto Forum:
  


Current Time: Sat Feb 15 01:36:27 CST 2025