RE: [xsl] Using not(...a nd ... ) to select nodes

Subject: RE: [xsl] Using not(...a nd ... ) to select nodes
From: "Lars Huttar" <lars_huttar@xxxxxxx>
Date: Thu, 10 Jul 2003 17:17:26 -0500
I wrote:
> I think you probably need to do Muenchian grouping using a composite
> key on name, type, and status.
> See http://www.dpawson.co.uk/xsl/sect2/N4486.html

To spell it out more, something like

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
	<xsl:output method="html" version="1.0" encoding="UTF-8" indent="yes"/>

  <xsl:key name="itemFromData" match="item" use="concat(name, '+', type, '+', status)" />
  
  <xsl:template match="/">
    <xsl:for-each select="/items/item[generate-id(.) =
            generate-id(key('itemFromData', concat(name, '+', type, '+', status))[1])]">
      <xsl:apply-templates />
      <br />
    </xsl:for-each>
  </xsl:template>
  
  <xsl:template match="text()">
    <xsl:value-of select="concat(., ' ')" />
  </xsl:template>
</xsl:stylesheet>



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


Current Thread