Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: resume on Exception

RE: resume on Exception

From: Mercadante, Thomas F <thomas.mercadante_at_labor.state.ny.us>
Date: Fri, 15 Oct 2004 11:11:56 -0400
Message-ID: <C9995D8C5E0DDA4A8FF9D68EE666CE07A7F998@exchsen0a1ma>


Bob,

Is your single update statement updating multiple rows? And you want to continue updating the remainder rows if an exception occurs?

If so, then you need a driving query and an update statement that will only update a single row. Your loop will continue even if an exception occurs.

Good Luck!

Tom Mercadante
Oracle Certified Professional

-----Original Message-----

From: Bob Metelsky [mailto:bobmetelsky_at_comcast.net] Sent: Friday, October 15, 2004 11:07 AM
To: oracle-l_at_freelists.org
Subject: resume on Exception

All, I know I can trap and exit on an exception but how can the program trap and continue?

say I have

while <condition>

       update xxx where recnum ... ;
            if  any_exception then
                write any_exception & recnum to file and continue;
            end if;

end loop;

any examples of this logic?

Thanks!
Bob

--

"Oracle error messages being what they are, do not highlight the correct cause of fault, but will identify some other error located close to where the real fault lies."

--

http://www.freelists.org/webpage/oracle-l
--

http://www.freelists.org/webpage/oracle-l Received on Fri Oct 15 2004 - 10:07:36 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US