The Xml Structure looks like such
<A>
<d1></d1>
<d2></d2>
<B-Collection>
<B>
<d3>
<d4>
<C-Collection>
<C>
<d5>
</C>
<C>
<d6>
</C>
</C-Collection>
</B>
<B>
<d7>
<d8>
<C-Collection>
<C>
<d9>
</C>
<C>
<d10>
</C>
</C-Collection>
</B>
So there is one A Node but many B Records which have many C children records
Table B has an Identity on it and that Identity is stored as a foreign key in table C
Using OpenXML how can I insert 4 B records, get each of there identities back, and then insert the associated C records with the B identities.
I would like to avoid using cursors if at all possible.
Thank you
<A>
<d1></d1>
<d2></d2>
<B-Collection>
<B>
<d3>
<d4>
<C-Collection>
<C>
<d5>
</C>
<C>
<d6>
</C>
</C-Collection>
</B>
<B>
<d7>
<d8>
<C-Collection>
<C>
<d9>
</C>
<C>
<d10>
</C>
</C-Collection>
</B>
So there is one A Node but many B Records which have many C children records
Table B has an Identity on it and that Identity is stored as a foreign key in table C
Using OpenXML how can I insert 4 B records, get each of there identities back, and then insert the associated C records with the B identities.
I would like to avoid using cursors if at all possible.
Thank you