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

  • Thread starter Per Hornshøj-Schierbeck
  • Start date
P

Per Hornshøj-Schierbeck

I have a Schema describing an XML feed i'm receiving. The problem is, when i
load it i get the above error.

In this schema i have several fields describing an article. Two of these
fields(tables) are called videos and sounds. They both contain a complex
type (table) called Types which contain from 0-unbound number of "type"
elements.

So the case is. Both the sounds and the videos nodes have types/type nodes,
which won't map to my DataSet. I don't think i can get the xml provider to
change the format, but is there any way i can add something to the schema to
allow the "same table" twice?


Thanks in advance
Per

Here is an example to describe the problem:
<xs:element name="sounds">
<xs:complexType>
<xs:sequence>
<xs:element name="sound" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<!-- other fields that isn't causing problems -->
<xs:element name="types" >
<xs:complexType>
<xs:sequence>
<xs:element name="type" type="xs:string"
maxOccurs="unbounded" minOccurs="0" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="videos">
<xs:complexType>
<xs:sequence>
<xs:element name="video" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<!-- other fields that isn't causing problems -->
<xs:element name="types" >
<xs:complexType>
<xs:sequence>
<xs:element name="type" type="xs:string"
maxOccurs="unbounded" minOccurs="0" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top