Chapter 26. The Constraint Class
The Constraint class
ensures data integrity in the disconnected
DataSet. ADO.NET includes two types of
constraints, both of which derive from the abstract
Constraint class and aren't
specific to any provider. The UniqueKeyConstraint
ensures that column values aren't repeated in a
single table and can optionally designate a specific column or group
of columns as a primary key. The
ForeignKeyConstraint ensures that column values in
a child table correspond to values in the related parent table. In
addition, the ForeignKeyConstraint can define
rules that affect how deletions and updates are propagated between
parent rows and their associated children.
|