EDIT: As Alochchi said, my decision is wrong. According to the specification, an element in xs: all can appear only zero or once. Sorry for the inconvenience
I think what you want is not consistency. A sequence defines not only elements, but also order. And in your case, the order may change. Have you tried xs: everything?
<xs:complexType name="myComplexType"> <xs:all> <xs:element name="x" type="xs:string" maxOccurs="unbounded"/> <xs:element name="y" type="xs:string" maxOccurs="1"/> </xs:all> </xs:complexType>
Another example might be to make it a sequence, but check the sequence maxOccurs="unbounded"
source share