You can use the INFORMATION_SCHEMA
tables for this. For example, the INFORMATION_SCHEMA TABLE_CONSTRAINTS
table.
Something like this should do it:
select *
from INFORMATION_SCHEMA.TABLE_CONSTRAINTS
where CONSTRAINT_TYPE = 'FOREIGN KEY'
You can use the INFORMATION_SCHEMA
tables for this. For example, the INFORMATION_SCHEMA TABLE_CONSTRAINTS
table.
Something like this should do it:
select *
from INFORMATION_SCHEMA.TABLE_CONSTRAINTS
where CONSTRAINT_TYPE = 'FOREIGN KEY'