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

Re: Grouping based on the sum of an attribute

Subject: Re: Grouping based on the sum of an attribute
From: "Spencer Tickner" <spencertickner@xxxxxxxxx>
Date: Fri, 26 Jan 2007 09:43:11 -0800
Re:  Grouping based on the sum of an attribute
Unreal David,, Thanks so much.

Cheers,

Spencer

On 1/26/07, David Carlisle <davidc@xxxxxxxxx> wrote:

<xsl:variable name="tcols" select="@cols"/> <xsl:for-each-group select="*" group-by="sum(@cols,preceding-sibling::*/@cols) idiv $tcols">

then:


$ saxon8 st.xml st.xsl \!indent=yes <?xml version="1.0" encoding="UTF-8"?> <table> <tr> <th colspan="3" rowspan="1"> Head </th> </tr> <tr> <td colspan="1" rowspan="1"> Column 1 </td> <td colspan="1" rowspan="1"> Column 2 </td> <td colspan="1" rowspan="1"> Column 3 </td> </tr> </table>

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

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.
Email
First Name
Last Name
Company
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.