[DDI-users] DDI 3.0 xsd question
Wendy Thomas
wlt at pop.umn.edu
Thu Feb 5 10:23:56 EST 2009
This is the place...on a conference call more later :) wlt
On Thu, 5 Feb 2009, Alerk Amin wrote:
> 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.
>
> _______________________________________________
> DDI-users mailing list
> DDI-users at icpsr.umich.edu
> http://www.icpsr.umich.edu/mailman/listinfo/ddi-users
>
Wendy L. Thomas Phone: +1 612.624.4389
Data Access Core Director Fax: +1 612.626.8375
Minnesota Population Center Email: wlt at pop.umn.edu
University of Minnesota
50 Willey Hall
225 19th Avenue South
Minneapolis, MN 55455
More information about the DDI-users
mailing list