Skip to Content
0
Former Member
Apr 26, 2011 at 03:03 AM

XSLT transformation in XML to ABAP: special characters issue

686 Views

Hi,

I am parsing well-formed XML file that has the following data (:

<projects><project><name>Wallis &amp; Futuna</name></project></projects>

I use XSLT transformation:

<xsl:transform xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sap="http://www.sap.com/sapxsl" version="1.0">
<xsl:strip-space elements="*"/>
 <xsl:template match="projects">
    <asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
        <PROJECTS>
          <xsl:for-each select="project">
            <PROJECT>
              <NAME>
                <xsl:value-of select="name"/>
              </NAME>
            </PROJECT>
          </xsl:for-each>
        </PROJECTS>
      </asx:values>
    </asx:abap>
  </xsl:template>
</xsl:transform>

If I use the above example without &amp;amp; everything works fine, but the original XML fails with exception CX_XSLT_DESERIALIZATION_ERROR and message "Error during deserialization". Googling around did not give an answer.

Any words of wisdom?

Edited by: Alexei Isaev on Apr 26, 2011 5:04 AM

Edited by: Alexei Isaev on Apr 26, 2011 5:05 AM