How you will set the datarelation between two columns?
Answer Posted / swapna
ADO.NET provides DataRelation object to set relation
between two columns.It helps to enforce the following
constraints,a unique constraint, which guarantees that a
column in the table contains no duplicates and a foreign-
key constraint,which can be used to maintain referential
integrity.
A unique constraint is implemented either by simply setting
the Unique property of a data column to true, or by adding
an instance of the UniqueConstraint class to the
DataRelation object's ParentKeyConstraint.
As part of the foreign-key constraint, you can specify
referential integrity rules that are applied at three
points,when a parent record is updated,when a parent record
is deleted and when a change is accepted or rejected.
Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
How to add an aggregate column?
What does ado stand for?
What is the difference between sqlcommand and sqldataadapter?
How to create data relations?
What is fill method in ado.net?
Can we load multiple tables in a dataset?
What is ado recordset?
List all the steps in order, to access a database through ado.net?
What is the executescalar method?
What are the benefits of using of ADO.NET in .NET 4.0?
What is ado data control?
Why edit is not possible in repeater?
What is ado and dao?
What is the difference between the clone() and copy() methods of the dataset class?
Explain the dataadapter class in ado.net?