Home » SQL & PL/SQL » SQL & PL/SQL » Object Reference Identnifications
Object Reference Identnifications [message #603658] Wed, 18 December 2013 04:18 Go to next message
ORAGENASHOK
Messages: 240
Registered: June 2006
Location: Chennai
Senior Member
I want to get tables name used in each procedure inside the package
I have tried with DBA_DEPENDENCIES and DBA_PROCEDURES.Count'nt get the details.

Let me know how can i get the details.
Re: Object Reference Identnifications [message #603661 is a reply to message #603658] Wed, 18 December 2013 04:31 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Oracle version?

Re: Object Reference Identnifications [message #603664 is a reply to message #603658] Wed, 18 December 2013 05:04 Go to previous messageGo to next message
mokarem
Messages: 109
Registered: November 2013
Location: Dhaka
Senior Member

Using following SQL, I am getting the desired output:

select * from dba_dependencies
where type = 'PROCEDURE'
and owner = 'SCOTT'
and referenced_type = 'TABLE'

Re: Object Reference Identnifications [message #603665 is a reply to message #603664] Wed, 18 December 2013 05:08 Go to previous messageGo to next message
cookiemonster
Messages: 13920
Registered: September 2008
Location: Rainy Manchester
Senior Member
that gives stand alone procedures, not procedures in packages.
Re: Object Reference Identnifications [message #603673 is a reply to message #603665] Wed, 18 December 2013 05:52 Go to previous messageGo to next message
mokarem
Messages: 109
Registered: November 2013
Location: Dhaka
Senior Member

Try this....

select *
from dba_dependencies
where type like 'PACKAGE%'
and owner = 'SCOTT'
and referenced_type = 'TABLE'
Re: Object Reference Identnifications [message #603678 is a reply to message #603673] Wed, 18 December 2013 06:30 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

No, this still does not give the dependencies for EACH PROCEDURE OF EACH PACKAGE.
Please try to read and understand the question.
And It has already been asked to you to FORMAT your post.

Re: Object Reference Identnifications [message #603680 is a reply to message #603678] Wed, 18 December 2013 06:48 Go to previous messageGo to next message
ORAGENASHOK
Messages: 240
Registered: June 2006
Location: Chennai
Senior Member
I have tried the ways given above it would work if stand alone proc.
As its inside package, need to extract.
Re: Object Reference Identnifications [message #603689 is a reply to message #603680] Wed, 18 December 2013 08:12 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Michel Cadot wrote on Wed, 18 December 2013 11:31

Oracle version?



If you don't answer our question, why should we answer yours?
In addition, this is NOT the first time you post a question and you know that Oracle version is MANDATORY.

Re: Object Reference Identnifications [message #603791 is a reply to message #603689] Thu, 19 December 2013 07:44 Go to previous messageGo to next message
ORAGENASHOK
Messages: 240
Registered: June 2006
Location: Chennai
Senior Member
sorry for the late reply ...

One env with 9i and another one with 11g.

Re: Object Reference Identnifications [message #603893 is a reply to message #603791] Fri, 20 December 2013 03:38 Go to previous messageGo to next message
ORAGENASHOK
Messages: 240
Registered: June 2006
Location: Chennai
Senior Member
Any Update?
Re: Object Reference Identnifications [message #603943 is a reply to message #603893] Fri, 20 December 2013 10:16 Go to previous message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Not possible in 9i.
In 11g, you must be able to decipher SYS.DEPENDENCY$.D_ATTRS column.

Previous Topic: Partitioning of tables
Next Topic: count according to headlines
Goto Forum:
  


Current Time: Sat Apr 20 09:54:27 CDT 2024