cancel
Showing results for 
Search instead for 
Did you mean: 

IDoc to file senario

Former Member
0 Kudos

Hi,

This is an idoc to file senario and in this senario,

PI receives multiple IDocs in a day and at end of the day PI needs to build a file with one header record, one detailed record for each IDoc and one tril record at the end file.

Could you please suggest me how can I achive this.

For better understanding i am providing file structure.

HDR RECORD

DETAILED RECORD1

DETAILED RECORD2

DETAILED RECORD3

DETAILED RECORD4

TRIL RECORD with total idocs proccessed.

Thanks in advance...

Sreeni

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi

"PI receives multiple IDocs in a day and at end of the day PI needs to build a file with one header record, one detailed record for each IDoc and one tril record at the end file."

If you need to collect IDOCs and create one file, i think in SAP's file port can be used, but adding header and trailer part

needs to be check if that can also be done or not.

If its PI 7.1 Ehp1 then you can use collect IDOC option which creates multiple "IDOC" and in target you can create

a structure with 1 header ,1 trailer and multiple records which can be mapped to "IDOC"

/people/shabarish.vijayakumar/blog/2010/01/22/idoc-packaging--sap-pi-71-ehp1-and-above

Regards,

Srinivas

former_member200962
Active Contributor
0 Kudos
PI receives multiple IDocs in a day and at end of the day PI needs to build a file

How are you collecting the IDOCs? Since the File should have details from all the IDOCs you should first collect the IDOCs and do the further processing....for more info on collecting IDOCs refer: /people/michal.krawczyk2/blog/2009/05/21/xipi-collecting-idocs--possible-ways-with-pros-and-cons--5-ways

Regards,

Abhishek.

Former Member
0 Kudos

Hi,

PI receives multiple IDocs in a day and at end of the day PI needs to build a file with one header record, one detailed record for each IDoc and one tril record at the end file.

Can u please give more details on this...

If the IDOC's are coming multiple times in a day say 100 times and each IDOC will have multiple IDOC's then what do u want...

I think u have to combile multiple IDOC's in source to a single IDOC and send at a time.. If not PI has to store these IDOC's and send them at the end of the day...

Please give exactly what u want to achieve...

Babu

rajasekhar_reddy14
Active Contributor
0 Kudos

Hi,

This can be done easily using message mapping it self, but you have to build structure like below

Header 1..1

    LineItem 1 ..unbounded

    Trailier 1

Regards,

Raj