[XMLSCHEMA-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Newbie: Question about XSD

From: Pete Cordell <petexmldev@codalogic.com>
Date: Mon, 14 Jul 2008 09:57:24 +0100
Message-ID: <009e01c8e58f$a534bcc0$ea00a8c0@Codalogic>
To: "Michael Kay" <mike@saxonica.com>, "'Mathieu Malaterre'" <mathieu.malaterre@gmail.com>, <xmlschema-dev@w3.org>
Re: Newbie: Question about XSD

----- Original Message From: "Michael Kay"
To: "'Mathieu Malaterre'"

>> B.
>>   I have to manipulate entry which value can be multiple, how
>> would do that ?
>> 1. As attribute:
>> <entry>1,2,3</entry>
>>
>> 2. As element:
>> <entry>
>>   <value>1</value>
>>   <value>2</value>
>>   <value>3</value>
>> </entry>
>
> (2) will be easier to validate and to process.

A variation on this might be to use XSD's xs:list construct.  XML schema 
lists are always white space separated (you can't choose the separator), so 
your list could look like:

    <entry>1 2 3</entry>

HTH,

Pete Cordell
Codalogic
For XML C++ data binding visit http://www.codalogic.com/lmx/
Received on Monday, 14 July 2008 08:58:19 GMT

Subscribe to the Stylus Scoop newsletter for helpful XML tips and tutorials.
Email
First Name
Last Name
Company

Download Stylus Studio 6 XML Enterprise Edition

Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2007 All Rights Reserved.