Home » SQL & PL/SQL » SQL & PL/SQL » track stored procedures and functions that are "used" in a schema
track stored procedures and functions that are "used" in a schema [message #203990] Fri, 17 November 2006 04:15 Go to next message
xxxyyyxxx
Messages: 2
Registered: November 2006
Junior Member
Hi,

I have a database with a lot of existing PLSQL code in stored functions/procedures/packages.
I am quite sure some of those, even though they are valid, are not in use any more.

Is there a way to track which PLSQL functions or procedures (even inside packages) have been executed, for example over a 1 month period?

I could implement it by adding a log mechanism inside each single procedure/function but I would rather avoid doing that if possible.

Thanks.

Re: track stored procedures and functions that are "used" in a schema [message #204011 is a reply to message #203990] Fri, 17 November 2006 05:36 Go to previous message
JRowbottom
Messages: 5933
Registered: June 2006
Location: Sunny North Yorkshire, ho...
Senior Member
You can do regular scans through v$sql and look for procedure calls, but that's not a brilliant solution.

I reckon adding logging to the code is the best option.

Adding a little logging call to the bottom of each package body would mean that whenever code in that package was called, then you'd log the fact.
Previous Topic: how to stop a running script but not exit from sqlpus
Next Topic: How can I find records which contains: '
Goto Forum:
  


Current Time: Thu Dec 08 10:19:02 CST 2016

Total time taken to generate the page: 0.11441 seconds