Grouping and Sorting in BizTalk Maps

Recently I received a requirement where grouping and shorting in BizTalk map was required to get the desired result.

Here I have a sample message which has list of contacts and their items for an account. Multiple contact nodes are there for multiple items with same contact email address , first name and last name..

Input message:

image.png

This message need to be transformed to a message with single node for a contact email address and all the items for a particular contact should be grouped within the contact.

Output message:

image.png

The suggested way to accomplish this would be using xslt style sheet. You can refer Muenchian method.

I generally avoid using external XSL file or custom-XSLT because I am not very much comfortable with XSLT. So I tried to achieve this by using .net helper class.

image.png

I am not sure how would be the performance in case of dealing with large message but it work well for normal size messages.

Also this would be easily readable and maintainable in comparison with XSLT.

For a new BizTalk developer to troubleshoot and/or change an existing map it will be more easy to do using .net helper and BizTalk Mapper rather than troubleshoot and/or change and entire custom-XSLT file without a visual representation.

Related Links:

http://social.technet.microsoft.com/wiki/contents/articles/22059.biztalk-server-grouping-and-sorting-operations-inside-biztalk-maps-using-the-muenchian-method.aspx

Loved this? Spread the word


BizTalk Server Monitoring

Gautam

Follow me here

About the Author

My name is Gyanendra Kumar Gautam. I am Solution Consultant, who basically works to hook the stuff together using Microsoft technologies like Azure PaaS, Azure Serverless Services, Microsoft BizTalk Server, and Azure DevOps Services.

You may also like

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}
turbo360

Never miss a good story!

 Subscribe to my blog to keep up with the latest news!