xsl-list
[Top] [All Lists]

Re: [xsl] Counting records

2008-12-08 11:14:53
<HesaValidate_Response xmlns="http://HesaValidateSqlSend";>

your xml is in the namespace "http://HesaValidateSqlSend";

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
version="1.0">
   <xsl:template match="/">
       <xsl:variable name="RowCount" select="count(//row)"/>

you need to give that namespace a prefix in your stylesheet and use that:

<xsl:stylesheet version="1.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
    xmlns:h="http://HesaValidateSqlSend";
    exclude-result-prefixes="h">

  <xsl:template match="/">
     <xsl:value-of select="count(//h:row)"/>



cheers
-- 
Andrew Welch
http://andrewjwelch.com
Kernow: http://kernowforsaxon.sf.net/

--~------------------------------------------------------------------
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>
--~--