SQL 2008 R2 - "Enforce Foreign Key Constraint"


Author
Message
William Fields
William Fields
StrataFrame User (252 reputation)StrataFrame User (252 reputation)StrataFrame User (252 reputation)StrataFrame User (252 reputation)StrataFrame User (252 reputation)StrataFrame User (252 reputation)StrataFrame User (252 reputation)StrataFrame User (252 reputation)StrataFrame User (252 reputation)
Group: StrataFrame Users
Posts: 80, Visits: 239
Hello,

In the SQL 2008 R2 GUI for Foreign Key Relationships, it has an "Enforce Foreign Key Constraint" option. What is the equivalent in the "new relationship" builder in DDT v7.6.0?

Reason I'm asking is that the "Enforce relationships for INSERTS AND UPDATES" option in the DDT will disable the delete and update rule comboboxes, but the "Enforce Foreign Key Constraint" in SQL does not disable the "INSERT and UPDATE Specification" options. So I'm confused if they are the same or not.

Thanks.
StrataFrame Team
S
StrataFrame Developer (4.7K reputation)StrataFrame Developer (4.7K reputation)StrataFrame Developer (4.7K reputation)StrataFrame Developer (4.7K reputation)StrataFrame Developer (4.7K reputation)StrataFrame Developer (4.7K reputation)StrataFrame Developer (4.7K reputation)StrataFrame Developer (4.7K reputation)StrataFrame Developer (4.7K reputation)
Group: StrataFrame Developers
Posts: 3K, Visits: 2.5K
Yes, they are the same option.  The "Enforce relationship for INSERTs and UPDATEs" option in the DDT is the "Enforce Foreign Key Constraint" option in SQL Server Management Studio.  It basically says whether the constraint is on or off.

ALTER TABLE tablename NOCHECK CONSTRAINT foreignKey;

We disabled the combo boxes because we decided that it didn't make sense for the constraint to be off but still cascade the deletes and updates, but it looks like SQL server allows this scenario.
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search