Home » RDBMS Server » Server Administration » Table Usage
Table Usage [message #371953] Tue, 26 December 2000 20:01 Go to next message
Nicholas Pinakis
Messages: 2
Registered: December 2000
Junior Member
Using TOAD I can select a table in the schema browser and select the "USED BY TAB" it displays a list that shows every trigger, package, procedure, view etc that has a relationship with this table.

I suspect that TOAD is either scanning the Database or more likely running an SQL script to provide this information.

Can someone help with some SQL script that I can run to provide the same listing outside of TOAD (ie in SQL Plus) ?

Thanks in advance for any assistance.

Cheers...Nicholas
Re: Table Usage [message #371957 is a reply to message #371953] Wed, 27 December 2000 04:53 Go to previous messageGo to next message
Marcus Fernando
Messages: 34
Registered: September 2000
Member
SELECT nested_level, type, name
FROM deptree
ORDER BY seq#;

This sql list all dependent objects.

SELECT * FROM ideptree;
This sql lists the same information in tree structure.
Re: Table Usage [message #371960 is a reply to message #371953] Wed, 27 December 2000 09:26 Go to previous message
me
Messages: 66
Registered: August 2000
Member
if you select privileges on dba views:
SELECT *
FROM DBA_DEPENDENCIES
WHERE REFERENCED_OWNER = 'OBJECT OWNER'
AND REFERENCED_NAME = 'OBJECT NAME'

if not use this one:
SELECT *
FROM USER_DEPENDENCIES
WHERE REFERENCED_NAME = 'OBJECT OWNER'
Previous Topic: Function based indexes
Next Topic: how to display table schema
Goto Forum:
  


Current Time: Thu May 16 21:54:08 CDT 2024