Skip to Content

make dynamic files based on fields in Idoc

Apr 18, 2017 at 11:11 AM


avatar image
Former Member

Hi Experts,

I ahve a scenerio in which data is coming from ECC side inform of IDOC.

Now this IDOC has fields, BankID and RunID. now, based on combination of both ID'S I have to generate multiple files. as in if combination of bankid and runin for an IDOC is 1 and A, other is 2and A than I have to generate 2 different files. if we have 3 combination than 3 different files.

Note that, in a single idoc, there would be just 1 record. ie. just 1 BankID and 1 Runid. and in ECC system, we are not transferring data immediately but collecting idoc and than triggering the data to PI.Structure of all the files which I will create is same, just that data is different.

Is it possible to create multiple files based on some field in SAP PI?

Pls help

Thanks in advance

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Manoj K Apr 18, 2017 at 11:28 AM


Create 2 Message Mappings:

1. in first MM sort all the idocs based on the combination of bank_id and runid so that you have group of IDOCS with same combination.

2.Create multipmapping by changing the occurrence of target message type to 0..n and now have a condition create if only for unique values.

BDW what happens when the same combination is more then once ? I believe you create a one file with multiple records .



Show 1 Share
10 |10000 characters needed characters left characters exceeded

Manoj is right. Just as addition: you can use XSL transformation to group source iDocs and split data to multiple files with one shot.

Regards, Evgeniy.