|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: using preceding-sibling to calculate acummulated
Hi Jaime,
At 11:33 AM 7/7/2004, you wrote: I need to show in HTML a column of a table that shows the acummulated quantity... If, for example, I have: Fun. Assuming your context node is each row element in turn, sum(total | preceding-sibling::row/total) should work. (Short for sum(child::total | preceding-sibling::row/child::total) ) The "+" operation won't work for this since the second argument "preceding-sibling::total" isn't a number (even if it did return anything, it'd be a node set). To add the numerical values of nodes in a set you can use the sum() function. More complex cases can be, um, "baroque". Cheers, Wendell
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! 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
|

Cart








