Do PI mapping based on inbound IDoc source system

1.1k views Asked by At

I have to send the goods movement via IDoc from 2 different SAP systems to S/4 HANA via SAP Process Orchestration (PO).

I need to recognize in S/4 HANA from which system the IDoc is coming, do some mapping based on the sender, and after the mapping, I have to book the goods movement.

My solution is to extend the standard IDoc type MBGMCR03 with 1 segment with 1 field (SOURCE_SYSTEM).

  1. How can I fill that field before creating/sending the outbound IDoc?
  2. On the receiving system ( in this case S/4 HANA), where can I do the mapping before using the standard inbound functionality?

The customer does not want to do any mapping in Process Integration (PI).

1

There are 1 answers

5
mkysoft On

There is already sender system exists as SNDPRT on EDI_DC40 segment.

<EDI_DC40 SEGMENT="1">
  <TABNAM>EDI_DC40</TABNAM>
  <MANDT>100</MANDT>
  <DOCNUM>405820</DOCNUM>
  <DIRECT>2</DIRECT>
  <IDOCTYP>IDOC_TYPE</IDOCTYP>
  <CIMTYP />
  <MESTYP>MESSAGE_TYPE</MESTYP>
  <SNDPOR>SAPXXX</SNDPOR>
  <SNDPRT>XXXCLNT200</SNDPRT>
  <SNDPFC>LS</SNDPFC>
  <SNDPRN></SNDPRN>
  <RCVPOR>ED_STATU</RCVPOR>
  <RCVPRT>LS</RCVPRT>
  <RCVPRN>LS</RCVPRN>
  <CREDAT>20131010</CREDAT>
  <CRETIM>162137</CRETIM>
  <SERIAL>20131010162137</SERIAL>
</EDI_DC40>