How can I list all foreign keys referencing a given table in SQL Server?

后端 未结 26 3059
梦毁少年i
梦毁少年i 2020-11-22 07:13

I need to remove a highly referenced table in a SQL Server database. How can I get a list of all the foreign key constraints I will need to remove in order to drop the tabl

26条回答
  •  野性不改
    2020-11-22 08:01

    First

    EXEC sp_fkeys 'Table', 'Schema'
    

    Then use NimbleText to play with your results

提交回复
热议问题