[xsd-users] Disable Xerces-C Unique Particle Attribution check
boris at codesynthesis.com
Mon Mar 22 11:48:17 EDT 2010
Catalin Roman <katalin.roman at gmail.com> writes:
> I am trying to use XSD(xsd-3.2.0-i686-windows) in VS2008, with
> Xerces-C(xerces-c-3.1.0-x86-windows-vc-9.0) to compile a schema that
> violates UPA; the schema fragment that's responsible for this is:
> <xs:choice minOccurs="0">
> <xs:element name="value" type="boolean"/>
> <xs:element name="value" type="byte"/>
To be precise, this fragment violates the "Consistent Element Declaration"
rule rather than the "Unique Particle Attribution" rule. In XML Schema
elements within the same type with the same name should have the same
> I would like to ask if I can "disable" the UPA check performed by the
> Xerces-C parser and if it's possible, how can I achieve that?
No, unfortunately it is not possible to disable the checking of the
> Any other hints or workarounds are also most welcomed.
The only way forward that I can think of is to fix the schema. You could
use a single 'value' element whose type is a union of boolean and byte
to achieve the above behavior in a legal way.
More information about the xsd-users