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

Re: Uniqueness operator for XPath?

  • From: David Carlisle <davidc@n...>
  • To: cce@c...
  • Date: Thu, 08 Feb 2001 19:01:08 +0000 (GMT)

xpath fail

>  I suppose you may think that this should be
> in the realm of schema,

probbaly yes, because a schema validator has many more options on what
to do on failure.

XPath's don't ever really fail, they just don't always select any nodes,
so if the author is expecting there is only one head and goes

  /html/!head/!title

and then in the document there are two <head>. One might hope to
get an error condition, but (presumably) in XPath there would be no
error, but the above XPath would just fail to select any nodes, just as
if there were not a <head> element at all. I'm not sure if this would be
the expected behaviour.

This is assuming the semantics of !head are (baring optimisation
concerns) the same as head[position()=1 and last()=1]

David

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

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-2013 All Rights Reserved.