W3C home > Mailing lists > Public > xmlschema-dev@w3.org > August 2009

Re: [Update #2] XML Schema 1.1 Tutorial

From: <noah_mendelsohn@us.ibm.com>
Date: Wed, 12 Aug 2009 11:19:57 -0400
To: "Costello, Roger L." <costello@mitre.org>
Cc: "xmlschema-dev@w3.org" <xmlschema-dev@w3.org>
Message-ID: <OFE17B85C7.8B38EEF2-ON85257610.0053F378-85257610.00543AB4@lotus.com>
Slide 50:

"If I had placed the assertion on the <Para> element my XPath expression 
would need to "look up" to the <Document> element (parent). That's not 
allowed. It's an error, in fact."

Nope, it's not an error, at least not in the eyes of a schema processor. 
It won't do what you want, but it's not a violation of the constraints on 
schemas and it results in no error indication in the PSVI.  What happens 
is that the XPath looking up to find the "Document" won't find it.  That's 
because the assertion is validated with the <Para> were the root of the 
XPath data model;  for this purpose, <Para> has no ancestors.

I think it would be better to say:

"If I had placed the assertion on the <Para> element my XPath expression 
would need to "look up" to the <Document> element (parent). In fact, that 
won't do what you want.  The <para> is the root for the XPath evaluation, 
so the XPath won't even see the <Document> element."  Or some such.

Noah

--------------------------------------
Noah Mendelsohn 
IBM Corporation
One Rogers Street
Cambridge, MA 02142
1-617-693-4036
--------------------------------------








"Costello, Roger L." <costello@mitre.org>
Sent by: xmlschema-dev-request@w3.org
08/08/2009 01:27 PM
 
        To:     "xmlschema-dev@w3.org" <xmlschema-dev@w3.org>
        cc:     (bcc: Noah Mendelsohn/Cambridge/IBM)
        Subject:        [Update #2]  XML Schema 1.1 Tutorial



Hi Folks,

Here are the updates I made to the XML Schema 1.1 Tutorial:

    1. I received many excellent comments and 
       incorporated them.

    2. I created 20 lab exercises. I recommend 
       working the exercises as you read through 
       the tutorial.


Here is the updated tutorial:

http://www.xfront.com/xml-schema-1-1/xml-schema-1-1.ppt


Here is the updated tutorial + labs + examples:

http://www.xfront.com/xml-schema-1-1/xml-schema-1-1.zip


As always, please let me know if there is anything in the tutorial that is 
unclear or if you find a typo. 

/Roger
Received on Wednesday, 12 August 2009 15:20:45 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:15:14 GMT