Hi,

I have a strange error with Saxon 9 and Saxon 8.

Here my xsl :

<xsl:template match="child::node()|attribute::*" priority="-10">
         <xsl:copy>
                  <xsl:apply-templates select="attribute::*" />
                  <xsl:apply-templates select="child::node()"/>
         </xsl:copy>
</xsl:template>

(nothing more is usefull to understand the problem).


Here my XML data :

<?xml version="1.0" encoding="UTF-8"?>
<data>
        <!-- <MontantAideTotal>0,00 </MontantAideTotal> -->
         <bloc-TotalAPayerEssai>
                 
         </bloc-TotalAPayerEssai>
</data>

Here what I get when running Saxon (9 or 8) :

Error at xsl:apply-templates on line 71 of file:/D:/test-encoding/remove-fields.xsl:
  SERE0008: Character in comment cannot be represented in the selected encoding (code 8364)
Transformation failed: Run-time errors were reported

Now, if I drop the <!-- and --> to remove the comment, all is fine !!!

And if I remove only the Euro symbol (without removing the comment, as below), no error !

<?xml version="1.0" encoding="UTF-8"?>
<data>
        <!-- <MontantAideTotal>0,00</MontantAideTotal> -->
         <bloc-TotalAPayerEssai>
                 
         </bloc-TotalAPayerEssai>
</data>


Any idea ?

Regards -- Ph D





--
==================================================
Philippe Drix -- R&D
Graphane Solutions

mobile : 06 74 78 34 97
fixe   : 02 41 22 10 11

www.graphane.com