Re: Executing Procedures

From: ExecMan <>
Date: Wed, 15 Feb 2012 08:32:44 -0800 (PST)
Message-ID: <>

On Feb 15, 9:59 am, Mark D Powell <> wrote:
> On Feb 15, 9:57 am, ExecMan <> wrote:
> > Hi,
> > We want to record into a table the owner of the procedure, who called
> > it, and the name.  So, when a procedure is executed how would I query
> > the data dictionary to retrieve this information?  I cannot find any
> > code which tells me these 3 pieces of information.
> > Regards
> The built-in audit feature can produce a record of who called what
> procedure when if you audit execute; otherwise, I believe you would
> need to modify the procedures to log usage.  Auditing must be turned
> on in advance.
> You can find out within a procedure who called it via the call stack.
> Tom Kyte has published routines for getting this information:
> HTH -- Mark D Powell --

That's a good procedure. But it does not do what I want. Say I am USER_A and I create a procedure PROCEDURE_A. Then I connect as USER_B and execute PROCEDURE_A in USER_A's schema, I want to know that USER_B was the caller, and USER_A is the owner.

That procedure, WHO_CALLED_ME actually returns the OWNER of the procedure, not the CALLER.

Any help?

Thanks! Received on Wed Feb 15 2012 - 10:32:44 CST

Original text of this message