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

Home -> Community -> Usenet -> c.d.o.misc -> Re: trapping pl/sql errors with line numbers

Re: trapping pl/sql errors with line numbers

From: Daniel Morgan <damorgan_at_exxesolutions.com>
Date: Thu, 19 Jun 2003 08:42:56 -0700
Message-ID: <3EF1DA00.DB9D251F@exxesolutions.com>


Jeff Smith wrote:

> I have been searching docs and sites but no luck.
>
> When catching unhandled errors in PL/SQL procedures using 8.1.7, is there
> any internal function that can record the line number that failed?
>
> If caught in an WHEN OTHERS THEN exception block, we record the SQLCODE, but
> it would be nice to know what line failed. Having the line from all_source
> would make it easier to debug.
>
> Regards,
> Jeff

No. But you can put a variable at the beginning of each block identifying the block in which the
failure occured and then write it as part of the message to the error logging table.

--
Daniel Morgan
http://www.outreach.washington.edu/extinfo/certprog/oad/oad_crs.asp
damorgan_at_x.washington.edu
(replace 'x' with a 'u' to reply)
Received on Thu Jun 19 2003 - 10:42:56 CDT

Original text of this message

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