Reputation: 59
Suppose emp table having views, functions, procedures, triggers. So how can i find table having these object_type.please explain me
Upvotes: 0
Views: 290
Reputation: 6346
Oracle also provides tools called utldtree. To install it you have to execute. utldtree.sql
from $ORACLE_HOME/rdbms/admin
.
Script creates a few object tables ideptree, deptree and procedure deptree_fill.
exec deptree_fill('TABLE',user,'YOUR_TABLE');
select * from deptree;
select * from ideptree;
Upvotes: 1
Reputation: 1088
You can use the USER_DEPENDENCIES or ALL_DEPENDENCIES view provided by Oracle. Please refer to the following links.
https://docs.oracle.com/cd/B19306_01/server.102/b14237/statviews_1041.htm#i1576452
http://www.oratable.com/which-objects-refer-to-this-table/
In your case you can fire the following query.
SELECT * from ALL_DEPENDENCIES
WHERE REFERENCED_TYPE = 'TABLE'
AND REFERENCED_NAME = 'EMP'
Upvotes: 2