The same table cannot be the child table in two nested relations

  • Thread starter Thread starter Chuck Cobb
  • Start date Start date
C

Chuck Cobb

I came across an interesting error yesterday. If you attempt to use ADO.Net
to import an XML file into a DataSet using the DataSet.ReadXML command, you
will receive something similar to the following error:

The same table cannot be the child table in two nested relations.

if there is a field in the table you are importing that has the same name as
the table. For example, I have a table called "Criteria" that has a field
in it called "Criteria". I have exported the contents of the table plus
other tables to an XML file. When I attempt to import the data back into
the dataset, I get an error. Fortunately, the solution to this was easy...
just change the field name to be something else other than the table name.

Microsoft has acknowledged this to be a bug in the following knowledgebase
article:

http://support.microsoft.com/default.aspx?scid=kb;EN-US;325696

Chuck
 
Back
Top