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

Re: Count a substring of an attribute in childnodes

Subject: Re: Count a substring of an attribute in childnodes
From: "Ragulf Pickaxe" <jawxml@xxxxxxxxxxx>
Date: Wed, 09 Mar 2005 13:26:04 +0000
calculating in xsl
really it is pretty confusing to people offering help if you post input and output from unrelated expressions.

Copy-paste/writing error, sorry



count() is very efficient but has nothing to do with the problem that you have: it counts the number of nodes in a set, or in xslt2 it counts the number of items in a sequence. It has nothing to do with calculating totals.

I thought I had seen count being used in the way I tried (counting the total of node values in a given nodeset). After rereading, I see that it must have been sum, that I was thinking of.


I tried select="sum(number(colspec[contains(@colwidth,'*')]/substring-before(@colwidth,'*')))" instead, but this does not work either. So it will be the recursive template.
I must say that I find I still lack understanding of XPath :-(


Regards,
Ragulf Pickaxe :-/

_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today it's FREE! http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/


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.