Other Languages - Inline Xslt Call template - Microsoft Biztalk

Asked By Antariksh Mistry on 11-Jan-12 05:11 AM
Hi All,

I have created an xslt, which gives the following error: The Scripting functoid, that connects to target node 'action', has an error in its 'Xslt Call-Template' definition: 'There is not an xsl:template node at the root of the xslt.'

The scenario is that i need i already have one action called <ns0:action name="data">in input instance file ..........
Other 2 actions <action name="declare"> & <action name="calculateformula">I have to hardcode using xslt

My input xml file will have only one action but the output xml should be like show below. </ns0:action name>

<action name="declare">
  <attribute dtype="String" name="ContactID" value="" />
- <action name="calculateformula">
  <attribute out_var="ContactID" formula_name="contact_id" />
- <ns0:action name="data">
</ns0:action name>

I have already created xslt as below but it gives error. The script functoid, i have used is connected to the action node in MAP. Please find the XSLT file below..

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-com:xslt" xmlns:var="http://astea.com.schema.bc.customer_request/var">

<xsl:template match="*| /">
<action name="declare">

<xsl:variable name="var:var1"  select="'string'"/>
<xsl:attribute name="dtype">
<xsl:value-of select="$var:var1" />

<xsl:variable name="var:var2" select="'ContactID'" />
<xsl:attribute name="name">
<xsl:value-of select="$var:var2" />

<xsl:variable name="var:var3" select="''" />
<xsl:attribute name="value">
<xsl:value-of select="$var:var3" />

<action name="calculateformula">
<xsl:variable name="var:var4"  select="'ContactID'"/>
<xsl:attribute name="out_var">
<xsl:value-of select="$var:var4" />

<xsl:variable name="var:var5" select="'contact_id'" />
<xsl:attribute name="formula_name">
<xsl:value-of select="$var:var5" />


kalpana aparnathi replied to Antariksh Mistry on 11-Jan-12 02:18 PM

Like an inline XSLT script, an inline XSLT call template must connect directly to a destination node. However, an inline XSLT call template may use links from the source schema and from other functoids.

The call template is responsible for creating the destination node and any of its substructures.

A sample XSLT call template that concatenates two elements appears in the Input script buffer when you select Inline XSLT Call Template in the Select script type dropdown.


The number of input parameters to the relevant Scripting functoid, configured to use an inline XSLT Call Template, does not match the number of parameters expected by that template.

User Action

Ensure that the number of input parameters to this Scripting functoid matches the number of parameters expected by the inline XSLT Call Template configured for this Scripting functoid.

Jitendra Faye replied to Antariksh Mistry on 11-Jan-12 10:52 PM
Follow this link-


Here you will get example.
Antariksh Mistry replied to kalpana aparnathi on 12-Jan-12 12:09 AM
Hi kalpana,

Thanks for replying .....

Here in my case there is no incoming link..
At script functoid used is connected to the action element of destination node.
The main challenge here is to create 2 axtra action nodes using either inline xslt or inline xslt call template.
ie recursion for action node

One with action { name="declare"}
and ther with { action name="calcuateformula" }

these two action also have attributes...

Antariksh Mistry replied to Jitendra Faye on 12-Jan-12 12:12 AM
Hi Vickey,
Thanks for the reply..

will suerly go through the examples and try getting the soultion. Do let me know if u get some more added details.