In relational database we will link multiple tables with foreign key and unique key reference. How can we check any table linked with multiple tables through foreign key relationship. We can use below query to get all information.
We need to change the table name accordingly.
SELECT TABLE_NAME, COLUMN_NAME, CONSTRAINT_NAME, REFERENCED_TABLE_NAME, REFERENCED_COLUMN_NAME FROM INFORMATION_SCHEMA.KEY_COLUMN_USAGE WHERE REFERENCED_TABLE_NAME = 'table_name';
We need to change the table name accordingly.
0 Comments
Post a Comment