W3C home > Mailing lists > Public > xmlschema-dev@w3.org > November 2002

deterministic or ambiguous?

From: Nell Golding <nell_golding@hotmail.com>
Date: Wed, 06 Nov 2002 10:49:25 +0000
To: xmlschema-dev@w3.org
Message-ID: <F166PczRXEw8eHvnilC00014abf@hotmail.com>


Hello,

I have created a XML schema and a sample XML document. According to XMLSpy 
4.4 the document seems to be valid and XML schema compliant to the W3C 
Specification.

All other Tools (Topologi Schematron and Markup Editor, XML Schema Validator 
from Microsoft) that I used for validation reply that my schema is not 
deterministic. They report that there are multiple definitions of some 
element that cause content model to be ambiguous.

I woud like to know, whether I make mistakes in schema definition and XMLSpy 
doesn't notice them, or these are bugs of the other tools.

Here is a part of my schema that causes difficulties:

<xs:element name="root">
  <xs:complexType>
       <xs:choice>
	  <xs:sequence>
	    <xs:element name="Ack_Nack" type="xs:string" fixed="ACK">
	       <xs:annotation>
		 <xs:documentation>Acknowledgement</xs:documentation>
		</xs:annotation>
	    </xs:element>
	    <xs:element name="Reason_Nack" type="leer"/>
	  </xs:sequence>
	  <xs:sequence>
	    <xs:element name="Ack_Nack" type="xs:string" fixed="NACK">
		<xs:annotation>
                  <xs:documentation>Rejection</xs:documentation>
		</xs:annotation>
	    </xs:element>
	    <xs:element name="Reason _Nack" type="Explanation_of_Nack" 
maxOccurs="unbounded">
		<xs:annotation>
                  <xs:documentation>Explanation to the rejection of the 
Templates</xs:documentation>
		</xs:annotation>
	    </xs:element>
	 </xs:sequence>
      </xs:choice>
   </xs:complexType>
</xs:element>

Regards,
Nill Golding.




_________________________________________________________________
Add photos to your e-mail with MSN 8. Get 2 months FREE*. 
http://join.msn.com/?page=features/featuredemail


Received on Wednesday, 6 November 2002 08:11:07 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:14:35 GMT