Scenario:

You are working as SQL Server developer, You need to provide the scripts to disable all the Foreign Key Constraint in SQL Server database. This might be scenario where you need to load one time data and you are ok if data violate referential integrity.

Solution:

Let's get the list of Foreign Key Constraints from a SQL Server Database before we generate the disable script.