on 2004 Dec 29 5:22 PM
Hello Friends,
I am sending an IDOC to a 3rd party using HTTP adapter. I need to bring in the Doctype into the payload of the message to the 3rd party.
I required second line as
<-
<!DOCTYPE cXML SYSTEM "http://xml.cxml.org/schemas/cXML/1.2.007/cXML.dtd">
->
so can i do using the XI Message Mapping.
Thanks,
Gaurav Jain
You can't do this with Message Mapping. You could use either XSL mapping or Java mapping.
XSL mapping is the easiest approach:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<!-- Add the Doctype declaration -->
<xsl:output method="xml" indent="no"
doctype-system="http://xml.cxml.org/schemas/cXML/1.2.007/cXML.dtd"/>
<!-- Identity Transform - copy the source XML to the output without any changes -->
<xsl:template match="node() | @*">
<xsl:copy>
<xsl:apply-templates select="node() | @*"/>
</xsl:copy>
</xsl:template>
</xsl:stylesheet>
Unfortunately there's a bug in how the SAP XSLT processor generates the doctype tag. It doesn't do it correctly.
Therefore you would need to write a Java map to add in the doctype and call it after your first map.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Gaurav / Wolff -
I applied the XSLT mapping and got the second line added but with an extra "[]" characters at the end.
I am not sure how to remove these and also not sure if Ariba would handle these characters.
Also if have a solution using the Java map can you tell me how to solve this using java map?
Thanks,
Tirumal
User | Count |
---|---|
66 | |
10 | |
10 | |
10 | |
10 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.