[DDI-users] DDI 3.0 xsd question
Alerk Amin
a.amin at uvt.nl
Thu Feb 5 10:10:45 EST 2009
Hello,
I have a question about a DDI 3.0 document that I am trying to
validate. I hope this is the right mailing list for this question: if
it is not, please let me know where I should mail this question.
The following snippet of XML validates properly, but it seems to me
like it should not:
<l:ConceptReference>
<r:ID>C_1</r:ID>
<r:ID>C_2</r:ID>
</l:ConceptReference>
Based on the documentation of the ReferenceType in reusable.xsd, the
Reference should have a URN, an ID, or both. 2 IDs (or 2 URNs) should
not be allowed.
In reusable.xsd, the schema for the ReferenceType contains:
<xs:choice maxOccurs="2">
<xs:element ref="URN">
...
</xs:element>
<xs:sequence>
<xs:element ref="ID">
...
</xs:element>
...
</xs:sequence>
</xs:choice>
In order to validate the way the documentation describes, it seems like
the scheme should instead contain:
<xs:choice>
<xs:sequence>
<xs:element ref="URN">
...
</xs:element>
<xs:sequence minOccurs="0">
<xs:element ref="ID">
...
</xs:element>
...
</xs:sequence>
</xs:sequence>
<xs:sequence>
<xs:sequence>
<xs:element ref="ID">
...
</xs:element>
...
</xs:sequence>
<xs:element ref="URN" minOccurs="0">
...
</xs:element>
</xs:sequence>
</xs:choice>
I would appreciate any help or explanation anyone can provide about
this. If my interpretation of the ReferenceType is incorrect, please
let me know.
Thank you for your help.
Best,
Alerk
--
Alerk Amin
Senior Software Developer
CentERdata
Room K737 (Tilburg University, Koopmans Building)
Postal address : PO Box 90153, 5000 LE Tilburg, The Netherlands
Visiting address : Warandelaan 2, 5037 AB Tilburg, The Netherlands
Telephone : +31-13-466 2243 / 8325
Fax : +31-13-466 2764
WWW : www.centerdata.nl
Disclaimer : See http://www.centerdata.nl/maildisclaimer.
More information about the DDI-users
mailing list