I have a requirement to produce an XSD. Under the root element there can be 0, 1 or multiple occurrences of any of 7 different elements, and these elements can occur in any order.
I can't use sequence, since the elements are not necessarily in a predefined order. This would be a valid schema, but it imposes too severe a restriction:
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="data">
<xs:complexType>
<xs:sequence>
I can't use all, since it doesn't allow maxOccurs to be unbounded, so this is an invalid schema:
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="data">
<xs:complexType>
<xs:all>
<xs:element name="address" minOccurs="0" maxOccurs="unbounded">
I have a feeling I've come up against another limitation of XSD, but I just thought I'd ask as I am new to XML Schemas.