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

RE: The same element in one content model with different type

From: Michael Kay <mike@saxonica.com>
Date: Thu, 3 Nov 2005 12:08:55 -0000
To: "'Michael Stolp'" <Michael.Stolp@stud.tu-ilmenau.de>, <xmlschema-dev@w3.org>
Message-ID: <E1EXdu1-0008Fg-OQ@lisa.w3.org>
xsd same element different type

> Hello list.
> 
> I have a problem to write a schema for the following:
> 
> <Bar id="Bar2" original_id="B5" zIndex="1">
> 	<Point posRef="pos2" id="Bar2.pt1" role="start"/>
> 	<Point posRef="pos3" id="Bar2.pt2" role="end"/>
> 	<Point posRef="pos5" id="Bar2.pt3" role="middle1"/>
> </Bar>
> 

Can't be done in XML Schema. All the Point elements within one Bar element
have to have the same type. You either have to change the design (e.g. the
element names), or use a different validation technology.

Michael Kay
http://www.saxonica.com/
Received on Thursday, 3 November 2005 12:09:12 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.