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

Help: Using enumeration that disregards case

  • To: <xml-dev@l...>
  • Subject: Help: Using enumeration that disregards case
  • From: "Davis, Nathan" <ndavis@j...>
  • Date: Tue, 24 Feb 2004 15:13:31 -0500
  • Thread-index: AcP7EqwHhCfbVUQIRnGecuL2GIizCQ==
  • Thread-topic: Help: Using enumeration that disregards case

using enumeration

Hi all,

 

This question is about XML Schema.

 

I want to create a simpleType > restriction > enumeration such as the following:

 

<xs:element name="pet-type">                                                       

  <xs:simpleType>                                                

    <xs:restriction base="xs:string">

      <xs:enumeration value="dog" />

      <xs:enumeration value="cat" />

      <xs:enumeration value="fish" />

      <xs:enumeration value="other" />                                             

    </xs:restriction>                                            

  </xs:simpleType>                                                     

</xs:element>

 

However, I also want to make it so that the instance document can have upper or lower case values, so that the following would all be valid:

 

<pet-type>CAT</pet-type>

<pet-type>Cat</pet-type>

<pet-type>cat</pet-type>

<pet-type>fiSh</pet-type>

<pet-type>Other</pet-type>

 

How can I do this with XML Schema?

 

Thanks,


Nathan Davis
Web Programmer
Division of State Court Administration
Judicial Technology and Automation Committee

 


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

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-2013 All Rights Reserved.