Difference between revisions of "Plsql search constraints"

From John Freier
Jump to: navigation, search
 
Line 9: Line 9:
 
  --and owner = 'OWNER'
 
  --and owner = 'OWNER'
 
  and constraint_name LIKE '%FK_NAME%';
 
  and constraint_name LIKE '%FK_NAME%';
 
 
Another way
 
  SELECT *
 
  FROM user_constraints
 
  WHERE table_name = '<your table name>'
 
    AND constraint_name = '<your constraint name>';
 

Latest revision as of 11:33, 3 October 2023

Run the query below to search for information on constraints.

  • OWNER = Schema
  • FK_NAME = Constraint name
select * 
from all_constraints
where 1=1
--and owner = 'OWNER'
and constraint_name LIKE '%FK_NAME%';