W3C home > Mailing lists > Public > xmlschema-dev@w3.org > February 2003

Can field be simpleContent in identity constraint?

From: Rainer Becker <rainerbecker.mail@t-online.de>
Date: Thu, 06 Feb 2003 22:51:19 +0100
Message-ID: <3E42D8D7.91D565C@t-online.de>
To: xmlschema-dev@w3.org

Hello newsgroup readers,

this question is about identity constraints. The Spec says

3.11.4 Identity-constraint Definition Validation Rules
Validation Rule: Identity-constraint Satisfied

4 [Definition:]  Call the subset of the Ětarget node setĚ
for which all the {fields} evaluate to a node-set with
exactly one member which is an element or attribute node
with a simple type the qualified node set.

That means, that a field can either be an attribute or
a simple type element. But the following instance validates
just fine in XSV, XMLSPY5, and MSXML, although the field is
a simple content element. Does the above definition include
simpleContent? Please clarify...

Thank you

Bis bald



<Liste xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"


<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
   <xs:element name="Liste">
            <xs:element ref="Buch" maxOccurs="unbounded" />

      <xs:unique name="UNIQUE_Buch">
         <xs:selector xpath=".//Buch" />
         <xs:field xpath=".//ID" />


   <xs:element name="Buch">
            <xs:element ref="ID" />
            <xs:element name="Name" type="xs:string" />

   <xs:element name="ID">
            <xs:extension base="xs:integer">
               <xs:attribute name="test" type="xs:string" use="optional"

Received on Thursday, 6 February 2003 16:48:59 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:55:59 UTC