Monday, 12 October 2015

BizTalk Map incoming Message to Single Output field - XSLT template

BizTalk Transformation : Map Incoming XML Message  to Single output field as string

To map incoming message to single out field, we will use xstl template in map.

1. Drag and drop Custom Scripting Functoid on your Map
2.Select  Inline XSLT Call Template.
3. Copy and Paste the following xslt code in "Inline Script" Section

<xsl:template name="called-template">
  <xsl:param name="param1" />
  <xsl:element name="DestinationField" namespace="">
    <xsl:text disable-output-escaping="yes">&lt;![CDATA[</xsl:text>
    <xsl:call-template name="identity" />
    <xsl:text disable-output-escaping="yes">]]&gt;</xsl:text>

<xsl:template name="identity" match="@*|node()">
    <xsl:apply-templates select="@*|node()" />
4. Map your root node name of source schema and destination field to this scripting Functoid.
5. Validate and Test your Map.