Preserve Order while mapping

There is the issue of the behavior of the mapping process creates invalid XML.

The input instance looks like this:

<xml> <loopA /> <loopB /> <loopA /> <loopB /> </xml>

However, when using the mapper, you create your output and it ends up looking like this:

<xml> <loopA /> <loopA /> <loopB /> <loopB /> </xml>

How to get this to work (only in R2) is to open up the btm file and change the following attribute from its default value of No to Yes in the mapsource element

PreserveSequenceOrder="No"

<mapsource Name="BizTalk Map" BizTalkServerMapperTool_Version="2.0" Version="2" XRange="100" YRange="420" OmitXmlDeclaration="Yes" TreatElementsAsRecords="No" OptimizeValueMapping="No" GenerateDefaultFixedNodes="Yes" PreserveSequenceOrder="No" CopyPIs="No" method="xml" xmlVersion="1.0" IgnoreNamespacesForLinks="Yes">

Here is the new code:

<mapsource Name="BizTalk Map" BizTalkServerMapperTool_Version="2.0" Version="2" XRange="100" YRange="420" OmitXmlDeclaration="Yes" TreatElementsAsRecords="No" OptimizeValueMapping="No" GenerateDefaultFixedNodes="Yes" PreserveSequenceOrder="Yes" CopyPIs="No" method="xml" xmlVersion="1.0" IgnoreNamespacesForLinks="Yes">

posted @ Thursday, August 28, 2008 12:36 PM

Print

Comments on this entry:

 re: Preserve Order while mapping

Left by . at 9/10/2008 1:57 AM
Gravatar

Hi Eric,

I am having this kind of problem with the 1.3 version of the BTAHL7. ¿Is there any solution to this problem for this version?

The only thing i have thought is to add an attribute to all of the segments that will carry the order in the message, and after applying the pipeline, to sort all of the segments based in that attribute...

¿Any suggestion?

Your comment:



 (will not be displayed)


 
 
 
Please add 3 and 7 and type the answer here:
 

Live Comment Preview:

 
«September»
SunMonTueWedThuFriSat
2930311234
567891011
12131415161718
19202122232425
262728293012
3456789