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: PL/SQL call stack

Re: PL/SQL call stack

From: <cpiodumpv_at_gmail.com>
Date: 10 Jan 2007 17:30:05 -0800
Message-ID: <1168479004.925216.25750@77g2000hsv.googlegroups.com>


> That's not what you originally asked. You wrote:
> "so we can log the current function/procedure executing"
> Different question ... different answer.
>
> What you want instead is the DBMS_APPLICATION_INFO built-in
> package. Look at the following procedures also documented in
> Morgan's Library at www.psoug.org.
>
> DBMS_APPLICATION_INFO.READ_CLIENT_INFO
> DBMS_APPLICATION_INFO.READ_MODULE
> DBMS_APPLICATION_INFO.SET_ACTION
> DBMS_APPLICATION_INFO.SET_CLIENT_INFO
> DBMS_APPLICATION_INFO.SET_MODULE
>
> At the beginning of each procedure or function do a set. In your
> exception handler do a get.
>
> You can also set a variable, global to the package, with the name
> of the current code block as you enter it but then you asked for
> a built-in package solution.
>
> Hope this helps.
> --

Good point this is not what I asked. Currently, at the beginning of the routine I push onto the stack encapsulated in the homegrown instrumentation utility and then pop at the end of the routine. The goal here is to not have to do or think about pushing or popping or setting etc... when i am developing. Currently, the only solution I see is to write my own utility that will derive the procedure/function name from the line number on the call stack. Received on Wed Jan 10 2007 - 19:30:05 CST

Original text of this message

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