|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: WDDX Recordset generic simplification
I realize it is often bad form to talk to yourself but hopefully it provides more insight into my problem and therefore more clarity for a possible solution. On 11/3/06, Eric Pheatt <eric.pheatt@xxxxxxxxx> wrote: Hi all, [snipped] I realize the following code does not work but it is the pull/procedural approach I keep getting stuck heading towards: <xsl:template match="var/recordset">
<xsl:variable name="rowCount" select="@rowCount"/>
<xsl:variable name="fieldNames" select="@fieldNames"/>
<xsl:for-each from="1" to="$rowCount" index="row">
<xsl:element name="{../@name}">
<xsl:for-each list="$fieldNames" index="col">
<xsl:element name="{$fieldNames[$col]}">
<xsl:value-of select="field[@name=$col]::child[position()=$row]"/>
<xsl:element>
</xsl:for-each>
</xsl:element>
</xsl:for-each>
</xsl:template>Can anyone point me towards a better approach using a push/functional approach to make simplification of wddx recordsets contextually generic? Thanks, Eric
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Cast Your Vote
We need your help – Vote for DataDirect XML Products!
Winners and finalists announced at SOA World Conference in November. 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
|







