xsl-list
[Top] [All Lists]

RE: [xsl] Problem with count() function using Xalan

2007-11-21 10:45:25
Can't see what you (or Xalan!) are doing wrong without seeing a source
document.

Michael Kay
http://www.saxonica.com/ 

-----Original Message-----
From: collins(_dot_)tchoumba(_at_)ext(_dot_)mpsa(_dot_)com 
[mailto:collins(_dot_)tchoumba(_at_)ext(_dot_)mpsa(_dot_)com] 
Sent: 21 November 2007 17:22
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: [xsl] Problem with count() function using Xalan

Hi i'm using XAlan 2.6 within a java application.
I'm getting trouble with the fucntion count().
It always return 1 even if the nodes i wich to count are more than 1.


I have some thing like this witihin my template:

  <xsl:template match="END-OF-PDU-FIELD" mode="service">
     <xsl:variable name="struct_ref" 
select="BASIC-STRUCTURE-REF/@ID-REF"/>
     <xsl:variable name="struct" select="
//DIAG-DATA-DICTIONARY-SPEC/STRUCTURES/parametre[(_at_)xmlDBId  = 
$struct_ref]/STRUCTURE"/>
     <xsl:variable name="taille_struct">
       <xsl:value-of select="count($struct/PARAMS/PARAM)"/>
     </xsl:variable>
          .....
  </xsl:template>

My STRUCTURE element contains a child PARAMS. And PARAMS contains  5
child(PARAM) but the count function always return 1 Do anyone 
come across a such problem yet ?

Thanks !!!
Collins


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: 
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>