cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tobia <tobia.confo...@linux.it>
Subject Re: Cocoon database access strategy
Date Wed, 04 Jul 2007 16:37:58 GMT
solprovider@apache.org wrote:
> > <xsl:template match="sql:query">
> >   <xsl:copy>
> >     <xsl:apply-templates select="@*|node()"/>
> >   </xsl:copy>
> >   <xsl:for-each select=".//sql:param">
> >     <sql:in-parameter value="{@value}" nr="{position()}"/>
> >   </xsl:for-each>
> > </xsl:template>
> >
> > <xsl:template match="sql:param">
> >   <xsl:text>?</xsl:text>
> > </xsl:template>
>
> I like it.  Add priority="2" to the first match to make certain
> sql:in-parameter elements are created before the sql:param are changed
> to question marks.

 From my understanding of XSLT it doesn't change sql:param's to ?s in
the source tree, but only in the result tree, so the processing order
is irrelevant.  Actually there is no predefined processing order: XSLT
is (mostly) a declarative programming language free from side effects.


Tobia

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message