This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 2011 - R-033: Request for clarification of identity constraint rules
Summary: R-033: Request for clarification of identity constraint rules
Status: CLOSED FIXED
Alias: None
Product: XML Schema
Classification: Unclassified
Component: Structures: XSD Part 1 (show other bugs)
Version: 1.0 only
Hardware: All All
: P2 normal
Target Milestone: ---
Assignee: Henry S. Thompson
QA Contact: XML Schema comments list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-07 20:07 UTC by Sandy Gao
Modified: 2009-04-21 19:24 UTC (History)
0 users

See Also:


Attachments

Description Sandy Gao 2005-09-07 20:07:15 UTC
Bullet 4.3 of section "Validation Rule: Identity-constraint Satisfied" states:

"If the {identity-constraint category} is keyref, then for each member of the 
qualified node set (call this the keyref member), there must be a node table 
associated with the {referenced key} in the [identity-constraint table] of the 
element information item (see Identity-constraint Table, which must be 
understood as logically prior to this clause of this constraint, below) and 
there must be an entry in that table whose key-sequence is equal to the keyref 
member's key-sequence member for member, as defined by Equal in [XML Schemas: 
Datatypes]."

Does this mean that the identity constraint referenced by the keyref must apply 
to the element the keyref is on or to one of its descendants, or may the 
identity constraint referenced by the keyref appear anywhere at all in the 
instance document?

If the former, the Primer contains an invalid example. Either way, this rule 
should be clarified.

See
http://lists.w3.org/Archives/Public/www-xml-schema-
comments/2001AprJun/0275.html 

Henry's response:
http://lists.w3.org/Archives/Public/www-xml-schema-comments/2001AprJun/0279.html
Comment 1 Sandy Gao 2005-09-07 20:07:44 UTC
The WG decided that the Structures spec needs a clarification of this 
constraint, and that the Primer has an example that is invalid. The 
commentator's interpretation is correct, namely, that the key or unique 
identity constraint to which a keyref refers must be within the scope of the 
element the keyref is on.

Erratum E0-22 added for Primer.

Structures erratum
http://lists.w3.org/Archives/Member/w3c-xml-schema-ig/2002Oct/0313.html
reviewed and approved at the Nov. 1 telecon.

Structures erratum E1-19 added