On Tue, Feb 23, 2010 at 6:28 PM, anil kumar
<anar(_dot_)leti(_at_)gmail(_dot_)com> wrote:
expected o/p
==============
<mezo eazon="AA">200</mezo>
<mezo eazon="AA">150</mezo>
.
.
<mezo eazon="BB">10,000</mezo> -- total of 24 AA records.
<mezo eazon="AA">300</mezo>
<mezo eazon="AA">50</mezo>
Are you working in XSLT 1.0 or 2.0 environment? Here's a 2.0 way of
solving this (this is untested):
<xsl:if test="(count(preceding-sibling::mezo) + 1) mod 24 eq 0">
<mezo eazon="BB">
<xsl:value-of select=". + sum(for $x in (1 to 23) return
preceding-sibling::mezo[$x])" />
</mezo>
</xsl:if>
If it's a 1.0 environment, we have to think of some other way of solving it.
--
Regards,
Mukul Gandhi
--~------------------------------------------------------------------
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>
--~--