RE: PL/SQL beginner

  • From: "Goulet, Richard" <Richard.Goulet@xxxxxxxxxxx>
  • To: <Lee.Robertson@xxxxxxxxxx>, "oracle-l" <oracle-l@xxxxxxxxxxxxx>
  • Date: Thu, 5 Feb 2009 15:52:39 -0500

Lee,
 
    It may be possible, but then it could also backfire so trail is
necessary, but you could try:
 
set serverout on size unlimited
begin
   <procedure1>;
    <procedure2>;
exception
   when others then dbms_output.put_line(sqlerrm);
end;
/
 
This should allow the procedures to run one at a time in serial, but if
an error occurs the pl/sql block will catch it, report the error, and
then exit back to sqlplus gracefully.
 

Dick Goulet 

 

________________________________

From: oracle-l-bounce@xxxxxxxxxxxxx
[mailto:oracle-l-bounce@xxxxxxxxxxxxx] On Behalf Of Robertson Lee -
lerobe
Sent: Thursday, February 05, 2009 12:08 PM
To: oracle-l
Subject: PL/SQL beginner


Hi,
 
Oracle 10gR2
AIX 6
 
Within a SQL*Plus script I have a number of calls to PL/SQL procs.
 
I want to, on failure of any of the PL/SQL scripts, drop back to the
calling SQL*Plus script and on return not go any further...i.e do not
call any of the other Stored Procs in the SQL*PLus script.
 
Ideally I would also like to report back to the calling SQL*Plus script
the errors from the failed PL/SQL.
 
I cannot re-engineer, I just need to make what is already there work if
it is at all possible.
 
Any suggestions after you have all stopped laughing ??   !!!
 
Regards and TIA
 
Lee
 
************************************************************************
***
The information contained in this communication is confidential, is
intended only for the use of the recipient named above, and may be
legally
privileged.

If the reader of this message is not the intended recipient, you are
hereby notified that any dissemination, distribution or copying of this
communication is strictly prohibited.

If you have received this communication in error, please resend this
communication to the sender and delete the original message or any copy
of it from your computer system.

Thank You.
************************************************************************
****

Other related posts: