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

Re: template match : node-set paring through multiple-

Subject: Re: template match : node-set paring through multiple-axis relationships
From: David Carlisle <davidc@xxxxxxxxx>
Date: Tue, 3 Jun 2003 19:12:15 +0100
template match node
>  I am disappointed that no
> one responded to my request, even to say "boy, that sure is a different
> problem".  :(

I didn't respond as I didn't understand your problem description (still
don't) I also don't understand your proposed solution, which seems very
strange.

                <xsl:variable name="b2"
select="parent::a/parent::a/child::b" />

so b2 is empty or not just if your parent and grantparent are called a
and you have an aunt called b.

<xsl:variable name="focus" select="current()"/>

so focus is the current node.


 test="current()[$b2]

$b2 is a node set so if used as a predicate it is true if and only if it
is non empty. It's a bit odd to use that in a path expression as it is a
constant predicate it doesn't depend on the nodes being filtered

[$focus]

the focus variable is always non empty as it is the current node, so
this predicate is the same as [true()] and never does anything.


[//

again it is very strange to start a predicate with // as it means that
you are filtering a node set based on a filter that will have a constant
value over the set being filtered.

Sorry I can't suggest what you should have as I'm not sure what your
transformation is trying to test.

David

________________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


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.