Question

I have input like

<Loop2300>
    <HD></HD>
    <DTP>
        <DTP1></DTP1> 
        <DTP2></DTP2> 
        <DTP3></DTP3>
   </DTP> 
   <DTP>
        <DTP1></DTP1> 
        <DTP2></DTP2> 
        <DTP3></DTP3>
   </DTP> 
</Loop2300>
<Loop2300>
    <HD></HD>
    <DTP>
        <DTP1></DTP1> 
        <DTP2></DTP2> 
        <DTP3></DTP3>
    </DTP>
    <DTP>
        <DTP1></DTP1> 
        <DTP2></DTP2> 
        <DTP3></DTP3>
    </DTP> 
</Loop2300>

I am putting the value of all DTP in SQL Table. Along with DTP I have one id element in the destination schema where I have to put the sequence number of HD.

So it will output like this:

1    DTP1 DTP2 DTP3

1     DTP1 DTP2 DTP3

2    DTP1 DTP2 DTP3

2    DTP1 DTP2 DTP3

I am using XSLT functoid inline xslt call template.

Inside that I am using

<xsl:template>
    <xsl:for-each select="TS834_2300_Loop/HD_HealthCoverage">
        <xsl:number value="position()" format="1. "/>
    </xsl:for-each>
</xsl:template>

code with no input and one output to the Id

But its giving error transform fail.

So what change do I need to do get the appropriate id?

Was it helpful?

Solution

Try connecting your <HD> source node to an Iteration functoid.

To flatten your values under <DTP> you will need the Table Looping functoid.

I don't have my BizTalk dev machine ready right now to build a complete prototype but this should give yo a starting point.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top