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

Re: Is there an OR for XSL IF?

Subject: Re: Is there an OR for XSL IF?
From: "Murray McDonald" <m.mcdonald@xxxxxxxxx>
Date: Wed, 4 Jan 2012 01:13:20 -0500
Re:  Is there an OR for XSL IF?
I assumed you were using XSLT 2.0 but in case you are using 1.0 here is some
elaboration on testing equality.  (The "or" operator is supported in both)

In XSLT/XPATH 1.0 the "=" operator compares atomic values.

In XSLT/XPATH 2.0 the "eq" operator is used to compare atomic values and the
"=" operator may be used to compare all items in the "left-side" sequence to
all items in the "right-side" sequence and will "return true" if any
left-side item is equal to any right-side item.  If the left and right sides
both specify single-item sequences then "=" will be semantically equivalent
to "eq".  Although you can "get away" with using "=" to compare atomic
values you're better off using "eq".

Take care

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.