handling error [message #37290] |
Tue, 29 January 2002 14:38 |
epro
Messages: 11 Registered: January 2002
|
Junior Member |
|
|
I have 2 pl/sql programs A and B, can be run as files names(@filename). I want to call them from a 3rd file called C.
I want to call B from C, only if there are no errors, exceptions in the 1st file(A). If there are errors it should not call B.
do you have any idea to share.
Thanks
|
|
|
Re: handling error [message #37293 is a reply to message #37290] |
Tue, 29 January 2002 16:20 |
Suresh Vemulapalli
Messages: 624 Registered: August 2000
|
Senior Member |
|
|
it is not possible to do that. create stored programs and call from file.
create procedure proc1 is
begin
--
end;
create procedure proc2 is
begin
--
end;
file 1:
declare
proc1_exception exception
begin
begin
proc1;
exception
when others then
raise proc1_exception;
end;
proc2;
exception
when proc1_exception then
dbms_output.put_line('exception raised while executing proc1');
when others then
dbms_output.put_line('exception raised while executing proc2');
end;
dont write any exception handlers in proc1
|
|
|
Re: handling error [message #37298 is a reply to message #37290] |
Wed, 30 January 2002 04:33 |
e-pro
Messages: 1 Registered: January 2002
|
Junior Member |
|
|
Thanks,
I will try that. Since the schema does not have previlege to create proc, I was thinking of that option, but no I have to ask for prev.
Thanks again. I will post if I have any questions.
|
|
|