Below is some TSQL from a script that has been generated by Management Studio.
The first command "CHECK ADD CONSTRAINT" creates a foreign key constration, and I guess forces a cascade delete.
What does the second command "CHECK CONSTRAINT " do?
I am porting the database to a compact database i want to be sure i have included everything.
/****** Object: ForeignKey [FK_FormData_Units] Script Date: 08/31/2010 10:16:18 ******/
ALTER TABLE [dbo].[FormData] WITH CHECK ADD CONSTRAINT [FK_FormData_Units] FOREIGN KEY([uni_id])
REFERENCES [dbo].[Units] ([uni_id])
ON DELETE CASCADE
ALTER TABLE [dbo].[FormData] CHECK CONSTRAINT [FK_FormData_Units]