If 2 tables are related using the dataRelation object,
do deletes cascade through the established in memory
relationship?
Can you related more that 2 tables using a single
DataRelation Object?
will the code below work?
DataColumn Tables;
DataColumn Chairs;
DataColumn TablesToChairs;
// Code to get the DataSet not shown here.
Tables = DataSet1.Tables["Tables"].Columns["TableID"];
TablesToChairs = DataSet1.Tables
["TableToChairRe l"].Columns["TableID"];
Chairs = DataSet1.Tables["Chairs"].Columns["ChairID"];
// Create DataRelation.
DataRelation relTablesToChai rs;
relTablesToChai rs = new DataRelation
("CustomersOrde rs", Tables, TableToChair,Ch airs);
// Add the relation to the DataSet.
DataSet1.Relati ons.Add(relTabl esToChairs);
Thanks for your help,
niv
do deletes cascade through the established in memory
relationship?
Can you related more that 2 tables using a single
DataRelation Object?
will the code below work?
DataColumn Tables;
DataColumn Chairs;
DataColumn TablesToChairs;
// Code to get the DataSet not shown here.
Tables = DataSet1.Tables["Tables"].Columns["TableID"];
TablesToChairs = DataSet1.Tables
["TableToChairRe l"].Columns["TableID"];
Chairs = DataSet1.Tables["Chairs"].Columns["ChairID"];
// Create DataRelation.
DataRelation relTablesToChai rs;
relTablesToChai rs = new DataRelation
("CustomersOrde rs", Tables, TableToChair,Ch airs);
// Add the relation to the DataSet.
DataSet1.Relati ons.Add(relTabl esToChairs);
Thanks for your help,
niv