H
hre1
hallo,
after numerous hours of searching for an explanation, i'm deadlocked.
here is my xsd:
<xs:complexType name="ct_1">
<xs:sequence>
<xs:element name="a1">
<xs:complexType>
<xs:sequence>
<xs:element name="b1"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="a2" minOccurs="0">
<xs:complexType>
<xs:sequence>
<xs:element name="b2"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="a3" minOccurs="0">
<xs:complexType>
<xs:sequence>
<xs:element name="b3"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ct_2">
<xs:complexContent>
<xs:restriction base="ct_1">
<xs:sequence>
<xs:element name="a1">
<xs:complexType>
<xs:sequence>
<xs:element name="b1"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="a2" minOccurs="0">
<xs:complexType>
<xs:sequence>
<xs:element name="b2"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
</xs:schema>
SCO means:TYPE REFINEMENT ERROR (content type incompatible with the
content type of the basetype)
and
XML Spy 2005 SP1 says: the content model of complex type ct_2 is not a
valid restriction of the content model of ct_1
but why? can anybody enlight me?
thanks in advance
jeff
after numerous hours of searching for an explanation, i'm deadlocked.
here is my xsd:
<xs:complexType name="ct_1">
<xs:sequence>
<xs:element name="a1">
<xs:complexType>
<xs:sequence>
<xs:element name="b1"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="a2" minOccurs="0">
<xs:complexType>
<xs:sequence>
<xs:element name="b2"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="a3" minOccurs="0">
<xs:complexType>
<xs:sequence>
<xs:element name="b3"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ct_2">
<xs:complexContent>
<xs:restriction base="ct_1">
<xs:sequence>
<xs:element name="a1">
<xs:complexType>
<xs:sequence>
<xs:element name="b1"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="a2" minOccurs="0">
<xs:complexType>
<xs:sequence>
<xs:element name="b2"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
</xs:schema>
SCO means:TYPE REFINEMENT ERROR (content type incompatible with the
content type of the basetype)
and
XML Spy 2005 SP1 says: the content model of complex type ct_2 is not a
valid restriction of the content model of ct_1
but why? can anybody enlight me?
thanks in advance
jeff