W3C home > Mailing lists > Public > public-xml-id@w3.org > April 2004

Multiple IDs per element in schemas 1.1

From: Elliotte Rusty Harold <elharo@metalab.unc.edu>
Date: Sun, 11 Apr 2004 11:45:44 -0400
Message-Id: <p06010200bc9f162632d5@[]>
To: public-xml-id@w3.org

A few random thoughts on a Sunday morning. I was reading through the 
XML Schema 1.1 requirements 
<http://www.w3.org/TR/2003/WD-xmlschema-11-req-20030121/> today, when 
I noticed the following proposal: Allow complex types more than one ID attribute (RQ-105)

Relax the constraint that a complex type may contain at most one 
attribute of type ID.


I'm not sure what sections xml:id exactly this would affect if 
adopted, but it does seem like it might well affect something in the 
xml:id spec, so I just thought I'd toss this out here, and see what 
people thought. There is an implicit assumption throughout the xml:id 
spec that each element has and should have at most one unique ID type 
attribute. Indeed, a lot of verbiage is expended  considering how to 
handle the case where this is not true. But what if we were to remove 
this requirement completely?

Currently, it is not possible for a *valid* element to have two 
attributes with ID type.  However it is definitely possible for an 
*invalid* document to have two such attributes. Neither the infoset 
nor XML 1.0/1.1 prohibits this. In the future, it seems it may be 
possible for a schema-valid document to have multiple ID type 
attributes. What if instead of trying to avoid this case, xml:id 
embraced it?

Anyway, I'm not sure exactly what text this might change in the 
xml:id spec; maybe the bit about not declaring non-xml:id attributes 
as type ID. But it might adjust how one thinks about some of these 

   Elliotte Rusty Harold
   Effective XML (Addison-Wesley, 2003)
Received on Monday, 12 April 2004 06:22:47 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 19:53:49 UTC