W3C home > Mailing lists > Public > xmlschema-dev@w3.org > August 2006

XSchema question

From: Sandra Martinez <sandra.martinez@nist.gov>
Date: Mon, 07 Aug 2006 09:17:18 -0400
Message-Id: <>
To: xmlschema-dev@w3.org

Could someone provide any ideas or work-around on the following issue:

I am trying to design a Xschema that allows an unordered list of elements 
where some of the elements are unbounded, have occurrences of 0 or 1,  or 1 
to unbounded.  Based on the  XSchema constraint that <xsd:all> does not 
allowed 0..unbounded elements, I decided to used the following work-around 
which works for an unordered list of unbounded elements but it does not 
work for the other two cases. The question is: How can I modified this 
XSxhema to allow an additional  element child <AAA> whose occurrence is 0 
or 1 and that could also be placed in any order (unordered) and also allow 
for an additional elemen <DDD> whose occurance is one to unbounded and that 
could also be placed in any order (unordered):

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
         <xsd:element name="AAA">
                 <xsd:complexType mixed="false">
                                 <xsd:sequence minOccurs="0" 
                                         <xsd:element name="BBB" 
type="xsd:string" minOccurs="0"/>
                                         <xsd:element name="CCC" 
type="xsd:string" minOccurs="0"/>

  valid XML instance 1:


valid XML instance 2:


valid XML instance 3:


valid XML instance 4:


Thank you in advanced,


Sandra I. Martinez
National Institute of Standards and Technology
100 Bureau Drive, Stop 8970,
Gaithersburg, Md. 20899

(301) 975-3579
Received on Monday, 7 August 2006 13:17:59 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:56:10 UTC