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

Re: comparing attributes if missing at times

Subject: Re: comparing attributes if missing at times
From: Michael Kay <mike@xxxxxxxxxxxx>
Date: Wed, 26 Mar 2014 13:12:57 +0000
Re:  comparing attributes if missing at times
On 26 Mar 2014, at 12:41, Szabo, Patrick (LNG-VIE)
<patrick.szabo@xxxxxxxxxxxxx> wrote:
:
>
> <xsl:for-each-group select="elem" group-starting-with="elem[@x !=
preceding-sibling::elem[1]/@x]">

Like all the other comparison operators, "!=" is implicitly existential. That
is, A!=B means "some a in A, b in B satisfies a!=b".

This is handy for "=", because you can say author="Smith" and it gives a
reasonable answer if there is more than one author.

It's very rarely useful for "!=", which is why most people advise against
using it. Use not(A = B) instead,

Michael Kay
Saxonica

Current Thread

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
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.