
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<!--The Parameter values will be fetched from exchange properties of the
Message -->
<xsl:param name="para1" />
<xsl:param name="para2" />
<!--Starting of the batch -->
<batchParts>
<xsl:for-each select="root/row/sub-row">
<!--Creating variable which will be used in many batch parts -->
<xsl:variable name="var1">
<xsl:value-of select="@attribute" />
</xsl:variable>
<xsl:for-each select="Subelemet/S-child">
<batchChangeSet>
<batchChangeSetPart>
<method>POST</method>
<!--entity set name and entity set -->
<entitysetName>
<entityset>
<!--Map all source fields to target fields -->
<tag1>
<xsl:value-of select="$var1" />
</tag1>
<tag2>
<xsl:value-of select="$para2" />
</tag2>
<tag3>
<xsl:value-of select="@attribute1" />
</tag3>
</entityset>
</entitysetName>
</batchChangeSetPart>
</batchChangeSet>
</xsl:for-each>
<!--You can add new entity set here of the same ODataAPI -->
</xsl:for-each>
</batchParts>
</xsl:template>
</xsl:stylesheet>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
7 | |
7 | |
7 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 | |
5 |