[Home] [By Thread] [By Date] [Recent Entries]
CROFT, MICHAEL wrote: [snip] Note that you problem is underspecified, or seriously misspecified. THerefore, i just included enough to make it work, without consideration on how it could be adapted to the problem you really have. Use this on the data you posted to the list only. <?xml version="1.0" encoding="ISO-8859-1"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format"> <xsl:key name="AlternateId" match="AlternateId"
use="parent::KeyGroup/@id"/> <xsl:template match="node()|@*">
<xsl:copy>
<xsl:apply-templates select="node()|@*"/>
</xsl:copy>
</xsl:template><xsl:template match="CrfActionGroup"/> <xsl:template match="partyId">
<xsl:copy>
<xsl:value-of select="key('AlternateId',../KeyGroup/@refid)[last()]/@value"/>
</xsl:copy>
</xsl:template>
</xsl:stylesheet>J.Pietschmann XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|

Cart



