Manjree Garg
12/10/2007 12:15:00 PM
Hi Wen
Thanks for your reply.
How would I define mant to many relationship between SampPrep and Experiment?
regards,
Manj.
"WenYuan Wang [MSFT]" wrote:
> Hello Manj,
>
> According to your description, you have tree tables: SampPrep, Experimement
> and ExpData. There is many to many relationship between SampPrep and
> Experiment. ExpData hold the reference to each of the table and store
> many-to-many relationship. If I misunderstood anything, please correct me.
>
> Many to many relationship is not native supported in ADO.net so far. If we
> want to define this type of relationship, we should have to add some
> additional relationship between them. (Such as: SampPrep-ExpData and
> Experiment-ExpData).
>
> System.Data.DataRelation dr1 = new DataRelation("SampPrep-ExpData",
> SampPrep.columns[SampPrepID],ExpData.Columns[SampPrepID]);
> System.Data.DataRelation dr2 = new DataRelation("Experiment-ExpData",
> Experiment.columns[ExperimentID],ExpData.Columns[ExperimentID]);
>
> Hope this helps. Feel free to update here again, if there is anything
> unclear. We are glad to assist you.
>
> Have a great day,
> Best regards,
> Wen Yuan
> Microsoft Online Community Support
> ==================================================
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
>