Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: SERVEROUTPUT Status
Thanks Daniel for your answer.
-- Syltrem OpenVMS 7.3-1 + Oracle 8.1.7.4 http://pages.infinit.net/syltrem (OpenVMS related web site, en français) ---zulu is not in my email address--- "Daniel Morgan" <damorgan_at_x.washington.edu> a écrit dans le message de news:1076433043.938326_at_yasure...Received on Tue Feb 10 2004 - 13:46:14 CST
> Syltrem wrote:
>
> > Hi Daniel
> >
> > Why do you (and others before) say that DBMS_OUTPUT does not belong to
> > production code?
> >
> > I have PL/SQL blocks that are executed in batch mode (for daily update
etc)
> > and I output messages like:
> >
> > 6576 rows updated
> > 8765 rows inserted
> >
> > at the end of the run so that when I look at the log file I know it did
what
> > I expected it to do. If it runs and no message is printed, how do I know
for
> > sure that it actually did something?
> > Of course, I could output those to a table (I do for some jobs that run
> > using DBMS_JOB) but for those running in the batch queue (this is
OpenVMS, a
> > little bit like a CRON on Un*x) I prefer having the log file. Again,
this is
> > a concept (log files for batch jobs) that does not exist on Windoze.
> >
> > So if you feel I should not, ever, use it, can you explain why?
> >
> > Thanks
>
> We say it because DBMS_OUTPUT is likely the most abused of all built-in
> packages. Far better to create a table and output the information as an
> insert showing date of run, start time, end time, and rows processed.
> That way you have a permanent graphable record.
>
> If no one is looking at the monitor 7x24 then DBMS_OUTPUT is not the
> tool of choice. A simple "clear screen" and your record is gone. What
> happens if the job fails? Record is gone. There are too many problems
> and not a single positive if viewed from the standpoint of a for-profit
> business where what is being done is a corporate record and has value.
>
> --
> Daniel Morgan
> http://www.outreach.washington.edu/ext/certificates/oad/oad_crs.asp
> http://www.outreach.washington.edu/ext/certificates/aoa/aoa_crs.asp
> damorgan_at_x.washington.edu
> (replace 'x' with a 'u' to reply)
>
![]() |
![]() |