xsl-list
[Top] [All Lists]

Re: [xsl] problem building a lookup table and find match from a different template

2006-08-30 09:51:44
Hi drkm,
Obviously, I am clueless with this. Thanks for being patient with me. I thought I used the following template to populate s:recs table.

<xsl:template name="build-rec-lookup-table">
<xsl:param name="dataset"/>

<s:recs>
<xsl:for-each select="$dataset/Item">
        <s:rec>
        <s:keyid><xsl:value-of select="@ID" /></s:keyid>
        <s:value><xsl:value-of select="@Value" /></s:value>
        </s:rec>
</xsl:for-each>
</s:recs>

</xsl:template>

What I need to do is to process 2 elements in a xml: dataset1 and dataset2. If same id exists in dataset2, display warning, then display the value from dataset2. If not found in dataset2, display dataset1 value. Maybe I am using a wrong approach to solve this. Your suggestion to a different approach would be greatly appreciated. Many Thanks!

_________________________________________________________________
Windows Live Spaces is here! It?s easy to create your own personal Web site. http://spaces.live.com/signup.aspx


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--