There are times when we need to find which are the tables that depend on a given table. This is useful when cleanup or archiving jobs have to pe performed and the interconnection of constraints is becoming a nuisance.
Lucky for us in the case of Oracle database is quite simple to search through all the constraints , as there exist a view called all_contraints.
The following query will search for all the constraints linked to the table MY_TABLE.
SELECT * from all_constraints
WHERE r_constraint_name IN
(SELECT constraint_name FROM all_constraints
Contribute to this site maintenance !
This is a self hosted site, on own hardware and Internet connection. The old, down to earth way 🙂. If you think that you found something useful here please contribute. Choose the form below (default 1 EUR) or donate using Bitcoin (default 0.0001 BTC) using the QR code. Thank you !