Subject: [xsl] count() problem From: Sam Saha <sam_saha1975@xxxxxxxx> Date: Sat, 17 Apr 2004 13:39:53 -0400 (EDT) |
Hi, How do I use the count() function to count the number of nodes that do NOT have a blank value. I have the following xml. In this case the count should be 6. <root> <nodes> <tele1>abc</tele1> <tele2></tele2> <tele3>abc</tele3> <tele4></tele4> <tele5>abc</tele5> <tele6>abc</tele6> <node1></node1> <node2>abc</node2> <node3>abc</node3> </nodes> </root> I am doing something like this: <xsl:variable name="num" select="count(root/nodes/*[starts-with(local-name(),'tele')!='' or starts-with(local-name(),'node')!=''])" /> But this counts even the nodes that have a blank value. Thanks Sam. ______________________________________________________________________ Post your free ad now! http://personals.yahoo.ca
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] use of the tags, Andreas L. Delmelle | Thread | RE: [xsl] count() problem, Andreas L. Delmelle |
[xsl] use of the tags, Kotes Mogili | Date | RE: [xsl] count() problem, Andreas L. Delmelle |
Month |