|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Keys working on nodeset?
Hi all,
I am working with keys where I get some input from a database.
I want to know if the following is possible. I have done some test
with input file, but in actual application the input will be passed as
a nodeset like below.
I have only found references to using keys on different documents, I
haven't been able to find references for keys on nodesets - did I not
look properly, or is this indeed not possible?
<?xml version="1.0" encoding="iso-8859-1" ?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:param name="Input" select="''"/>
<xsl:key name="key-test" match="Something" use="some-attribute"/>
<xsl:template match="/">
<xsl:for-each select="$Input/Root-element">
<xsl:for-each select="key('key-test',Something/@some-attribute)">
Do something
</xsl:for-each>
<xsl:for-each>
</xsl:template>
</xsl:stylesheet>
If this is not possible, then it falls back to the question I had a
couple of weeks ago, which Michael Kay answered, on how to transform
one document with multiple extra documents, all generated in
memory/from a database. This in .NET. (MK answered that I should pass
on a nodeset, which is what I plan to, if the above will work).
Thank you very much,
Ragulf Pickaxe
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








