Object dependencies
                                                 Last update (2008-03-27 13:51:09)
                                                                                                                   Date added (2008-02-27 11:50:24)

Summary
When for example rename a table or add a new column to the table the objects (procedures, packages, triggers etc) what references the table get invalid. To find which objects have a reference to table HELPDESK.S_RECIPIENTS execute:
SELECT D.owner, NAME, TYPE, O.LAST_DDL_TIME, O.status, DEPENDENCY_TYPE 
FROM all_dependencies D, dba_objects O
WHERE O.OBJECT_NAME = D.NAME 
AND O.OWNER = D.OWNER 
AND referenced_owner = 'HELPDESK' 
AND referenced_name = 'S_RECIPIENTS';
All dependencies are in the view: ALL_DEPENDENCIES
Column               Description
------               -----------
OWNER                Owner of the object
NAME                 Name of the object
TYPE                 Type of object
REFERENCED_OWNER     Owner of the parent object
REFERENCED_NAME      Type of parent object
REFERENCED_TYPE      Type of referenced object
REFERENCED_LINK_NAME Name of the link to the parent object (if remote)
SCHEMAID             ID of the current schema
DEPENDENCY_TYPE      Whether the dependency is a REF dependency (REF) or not (HARD)
Another query
 SELECT dep.tree||obj.owner owner, obj.object_name, obj.object_type, obj.status, obj.LAST_DDL_TIME
  FROM DBA_OBJECTS obj,
       (SELECT dep.object_id, RPAD('*',3*LEVEL,'*') tree
          FROM PUBLIC_DEPENDENCY dep,
               (SELECT object_id 
                  FROM DBA_OBJECTS
                 WHERE owner = 'HELPDESK' 
				 AND   object_name = 'S_RECIPIENTS' 
				 AND   object_type  = 'TABLE') obj
          CONNECT BY PRIOR dep.object_id = dep.referenced_object_id
            START WITH dep.referenced_object_id = obj.object_id
            ORDER SIBLINGS BY dep.object_id DESC) dep
 WHERE dep.object_id = obj.object_id;
Reviews
Categories
Oracle DBA-> (147)
  Alertlog (3)
  Archivelog (5)
  Auditing (1)
  Backup - Recovery (19)
  Database files (6)
  Database options (2)
  DB links (2)
  Dependencies (1)
  Dictionary (2)
  Exp-Imp Datapump (6)
  Jobs (2)
  Mview (2)
  Networking (3)
  Objects (7)
  Parameters (2)
  Redologs (6)
  Roles - Grants (2)
  Rollback - Undo (8)
  Segments (3)
  Sequences (2)
  Sessions (14)
  SGA (14)
  Tables (10)
  Tablespaces (10)
  Temp (4)
  Toad (5)
  Transactions (1)
  Upgrade (2)
  Users (3)
Oracle APPS DBA-> (66)
Exadata (1)
Performance Tuning-> (59)
Oracle Real Cases (24)
Oracle Errors (23)
Oracle SQL tricks (32)
Oracle RAC (3)
Oracle Security (8)
Filters
Search