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

Posted on 2005-04-25
Last Modified: 2007-12-19
I am trying to read an XML file using the Dataset.readxml method.  Here is the XML File i am trying to read (simplified)

<?xml version="1.0" encoding="iso-8859-1" ?>
<!DOCTYPE ShopSiteOrders PUBLIC "-// DTD//EN" "">
                        <Title />
                        <MiddleName />
                        <Suffix />
                  <FullName>JO-ANNE GRANDE</FullName>
                        <Title />
                        <MiddleName />
                        <Suffix />

I keep getting this error when i try to run the command .readxml:

An unhandled exception of type 'System.ArgumentException' occurred in

Additional information: The same table (NameParts) cannot be the child table in two nested relations.

One thing i noticed is that if i change the name of one of the NameParts tables, it works just fine, so if you know how to change the name of one of these table names on the fly that may be an ok workaround although not preferred.  
Question by:rodmjay
    LVL 37

    Accepted Solution

    easy way to change the names would be to run it through a quick xslt transformation to change the names although this does not sounds optimal.

    LVL 8

    Author Comment

    I redesigned the app to use txt values instead of XML.  Thanks anyway

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Looking for New Ways to Advertise?

    Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.

    1.0 - Introduction Converting Visual Basic 6.0 (VB6) to Visual Basic 2008+ (VB.NET). If ever there was a subject full of murkiness and bad decisions, it is this one!   The first problem seems to be that people considering this task of converting…
    Microsoft Reports are based on a report definition, which is an XML file that describes data and layout for the report, with a different extension. You can create a client-side report definition language (*.rdlc) file with Visual Studio, and build g…
    This video is in connection to the article "The case of a missing mobile phone (". It will help one to understand clearly the steps to track a lost android phone.
    Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

    759 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    10 Experts available now in Live!

    Get 1:1 Help Now