Oracle: Object Dependencies

This article demonstrates a SQL query that lists Oracle views and functions and the functions and tables that are contained in them.


SELECT OBJECT_TYPE,OWNER,NAME
,REFERENCED_TYPE REF_OBJECT_TYPE
,REFERENCED_OWNER REF_OWNER
,REFERENCED_NAME REF_NAME
FROM ALL_DEPENDENCIES
WHERE TYPE IN ('VIEW','FUNCTION') --show views and functions
--show the functions and tables that they contain
AND REFERENCED_TYPE IN ('FUNCTION','TABLE')
ORDER BY 1,2,3;

Leave a Reply

Your email address will not be published. Required fields are marked *