cancel
Showing results for 
Search instead for 
Did you mean: 

Merging of messages depending upon a particular field value from IDOC

Former Member
0 Kudos

Dear All,

I have a requirement where I need to merge two messages.( message1 and message2).Sender is IDOC and receiver is File.

The requirement for merging depends upon a particular field from IDOC which has 5 characters.

eg.Say there are 5 transactions and at the end of the 5th transaction the merging should happen.So for first

transaction the value of the field might be ABCD0( 0 will always be the indication for first record)and for the 2nd,3rd,4th transactions it will be of 4 characters ( XXXX,YYYY,cccc)and for the last transaction the value might be KAXRz(z will always be the indication for last record).

Now whenever we find "0" the merging should start and for "z" it should merge all records( 5 transactions).Please note that I will avoid using BPM.

Let me know the best way to achieve this.

Accepted Solutions (1)

Accepted Solutions (1)

rajasekhar_reddy14
Active Contributor
0 Kudos

Hi Deepa,

Its very easy to achieve your requiremnet,you have to use to check end condition use pattern ,

like suppose if you want end the condition when message contains Z,the pattern format would be !(Value CP 'z').it ends the condition and use container element to store the all messages in your case 5,its sends as one message.

use one Receiver step to receive messages,then use one block inside use loopstep,add end condition to that loop assign collected messages to container and send it.

or

use BPM,but standard approch implemneting use patterns,already predefned patterns available check the patterns which one suits for your requirement.

Regards,

Raj

Former Member
0 Kudos

Hi,

But I need the messages to split up and append the transactions.

Let me close this thread and create a new one to have more clarity on my requirement.

Thanks to all for your valuable time.

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Dheepa,

For N:1 scenarios you have to use BPM for sure. You cannot use 2 senders for the same receiver determination normally.

So , you have to go for BPM.

Regards,

Hemanthika

Former Member
0 Kudos

Hey,

There r various ways to collect Idocs.See if the below links help you.

Packaging - /people/sravya.talanki2/blog/2005/12/09/xiidoc-message-packages

With time limit - /people/daniel.graversen/blog/2006/09/07/using-a-bpm-to-collect-messages-for-a-set-interval-of-time

Without BPM - /people/stefan.grube/blog/2006/09/18/collecting-idocs-without-using-bpm

With Correlation - /people/sravya.talanki2/blog/2005/08/24/do-you-like-to-understand-147correlation148-in-xi

The most reliable

http://help.sap.com/saphelp_nw04/helpdata/en/08/16163ff8519a06e10000000a114084/content.htm

Thanks,

Vijaya.

Former Member
0 Kudos

Hi Deepa,

You have to use BPM to achieve your scenario's requirement.

Thanks,

Pooja