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

Re: xsl:key, predicates and documents.

Subject: Re: xsl:key, predicates and documents.
From: Nic Gibson <nicg@xxxxxxxxxx>
Date: Fri, 14 May 2010 13:47:50 +0000
Re:  xsl:key
On Fri, May 14, 2010 at 02:36:18PM +0100, Andrew Welch wrote:
> > So, I created keys that look like this:
> >
> > ? ?<xsl:key name="term-key" select="e[@PER='n']" use="@HW"/>
> > ? ?<xsl:key name="person-key" select="e[@PER='y']" use="@SUR"/>
> ...
> > <xsl:template match="eData[@PERS='n']">
> > ? ?<xsl:variable name="exact" select="key('term-key', @HW)"/>
> > ? ?...
> >
> > </xsl:template>
> >
> > We know that there are matches yet this doesn't work unless
> > we remove the predicate from the key definition. Are predicates
> > usable in key definitions?
> 
> It's much harder to help without seeing any input, but I can see a PER
> vs PERS difference in the code there... is that it?
> 

Good point but that's just my retyping error. The attribute is @PER.
I'm just trying to get some data from its owner

nic

> 
> -- 
> Andrew Welch
> http://andrewjwelch.com
> Kernow: http://kernowforsaxon.sf.net/

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.