26.1 CommentsTroubleshooting

26.1 Comments/Troubleshooting

Constraint objects are contained in a ConstraintCollection . Every DataTable exposes a ConstraintCollection through its Constraints property, which can contain UniqueKeyConstraint and ForeignKeyConstraint objects.

Both UniqueKeyConstraint and ForeignKeyConstraint classes can be created manually. In addition, a UniqueKeyConstraint may be created automatically when filling a DataSet with schema information, and both a ForeignKeyConstraint and a UniqueKeyConstraint may be generated when a DataRelation is defined and added to a table. For more information, refer to Chapter 10.



ADO. NET in a Nutshell
ADO.NET in a Nutshell
ISBN: 0596003617
EAN: 2147483647
Year: 2005
Pages: 415

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net