[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Calculating Column Total

Subject: Calculating Column Total
From: Shashank Jain <shashankjain@xxxxxxxx>
Date: Wed, 24 Mar 2010 14:33:32 -0500
 Calculating Column Total
HI All,

I am trying to calculate the total of all the columns which I am

creating dynamically.

My XML is


<event_template sp_doctypes="Research Note, Prior Stock Report, Stock

      <event  r_version_label="[1.0, CURRENT]" />

      <event  r_version_label="[2.0, CURRENT]" />


  <event_template sp_doctypes=" Prior Stock Report, Stock Report"

      <event  r_version_label="[1.0, CURRENT]" />

      <event  r_version_label="[2.0, CURRENT]" />

       <event  r_version_label="[1.0, CURRENT]" />

      <event  r_version_label="[2.0, CURRENT]" />



and this is the template I am using

<xsl:template name="Col_Total_Num_Mand">

         <xsl:for-each select="event_template ">

        <xsl:variable name="MandatoryDocs" select="@sp_doctypes"/>

        <xsl:variable name="StrArray"

        <xsl:variable name="test" select="count($StrArray)"/>

    <xsl:value-of select="count(child::event)*$test"/>



What I am trying to achieve is the total of events*(test) for all the


I am able to do it for individual event_template but not able to add
them all.

Hotmail has tools for the New Busy. Search, chat and e-mail from your inbox.

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.