Skip to Content

Separation of iFlows using iDoc party setup? PI AEX

Hi all,

we have the following situation. We are sending ORDERS.ORDERS05 IDocs from ERP to PI 7.4 AEX and from there to multiple receivers. Some go to SNC, other do "direct communication" with the respective supplier

1. ERP (IDoc) --> PI --> SNC (ABAP Proxy)

2. ERP (IDoc) --> PI --> Supplier 1 (HTTP_AAE)

3. ERP (IDoc) --> PI --> Supplier 2 (HTTP_AAE)

...

The control records of the IDocs that are sent from ERP look like this:

1. To SCN

MESFCT = SNC


SNDPOR = ERPSYS

SNDPRN = LOGERP

SNDPRT = LS

SNDPFC = <empty>

RCVPOR = PISYS

RCVPRN = 1234 (Party number of one supplier that is handled by SNC)

RCVPRT = LI

RCVPFC = LF

2. To Supplier 1

MESFCT = EDI


SNDPOR = ERPSYS

SNDPRN = LOGERP

SNDPRT = LS

SNDPFC = <empty>

RCVPOR = PISYS

RCVPRN = 4321(Party number of the supplier 1 that does direct communication)

RCVPRT = LI

RCVPFC = LF

The first scenario to SNC already existed and was built using an iFlow and standard XI Content provided by SAP (SNC inbound interface is ReplenishmentOrderNotification_In). Let's assume the name is "iFlow_SNC"

Now if i want to add the second scenario with direct communication to supplier to a new iFlow (say "iFlow_EDI_1") NWDS doesn't let me do this because the sender service and sender interface are already in use by "iFlow_SNC". I know I can just add interfaces to that iFlow_SNC and use receiver split with XPath to route to the correct receiver but I hesitate to do so because when looking into future we may have say 100 suppliers and the iFlow will get hard to maintain by then.

Questions:

1. Are there any best practice to deal with such situations (Same IDoc sender system / service to multiple receiver)

2. I fiddled around with parties (assigning the business system of ERP to a party and then creating a new iFlow based on that) but as you might expect, still iFlow_SNC gets chosen and routing fails because there is no rule for supplier 1 there. Is Party setup the right way here? If so, what did I do wrong?

Many thanks and kind regards

Jens

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    Posted on Apr 09, 2015 at 03:31 PM

    Hi Jens

    As you are using partner type LI for the IDoc partner profile, your scenario is exactly the type of scenario that should use party object and virtual receiver.

    Please refer to the following threads where I have the usage of virtual receiver for interfaces that have same sender system and sender IDoc but different receiver.

    Unfortunately, not many organisation/developer is aware of this concept, and the workarounds to enable multiple receivers end up being difficult to maintain/extend. The two common approaches are:

    1) Use single receiver determination with multiple conditions for each receiver - adding/removing new receivers require editing this "common" object which sometimes can lead to unwanted results (i.e. transporting a condition that is not ready for Production yet into Production!)

    2) Using enhanced receiver determination to use a message mapping to perform RFC/JDBC lookup on a database table to determine receiver.

    Anyway, to cut the story short, for each IDoc partner

    i) create a Party to represent the partner and maintain the IDoc partner details under the Party identifier

    ii) create a separate iFlow object which uses the Party above as a virtual receiver

    The Wiki by Harish also elaborates more on this.

    Also, you do not need a Party object for the ERP business system. So the generated ICO will have something like this:-

    Sender Party = <blank>

    Sender Component = ERP

    Sender Interface = ORDERS05 (with IDoc namespace)

    Virtual Receiver Party = Party object (i.e. for RCVPRN 1234 to SNC)

    Note also that the actual Receiver Component in the Receiver Determination step of the ICO does not necessarily have to be the same value of the Virtual Receiver.

    Rgds

    Eng Swee

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Apr 09, 2015 at 08:14 AM

    Hi Jens,

    1. Are there any best practice to deal with such situations (Same IDoc sender system / service to multiple receiver)

    -->> The best practice is having one receiver determination or iflow for one sender interface and system. But in your case it would be good to create a new iflow to avoid customization of standard object.

    2. I fiddled around with parties (assigning the business system of ERP to a party and then creating a new iFlow based on that) but as you might expect, still iFlow_SNC gets chosen and routing fails because there is no rule for supplier 1 there. Is Party setup the right way here? If so, what did I do wrong?

    -->> you can use the concept of virtual receiver and add party or service as virtual receiver. It will work for your case. and you need to maintain the receiver determination condition in all iflows.

    Please refer below wiki for reference

    Virtual Receiver use in Receiver Determination B2B(Idoc to (File,Idoc or any other system)) - Process Integration - SCN …

    regards,

    Harish

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Apr 13, 2015 at 04:04 AM

    Hi Jens,

    >>>>>1. Are there any best practice to deal with such situations (Same IDoc sender system / service to multiple receiver)

    Another approach is with enhanced receiver determination with operation mapping, with in the mapping based on RCVPRN you can create receiver then you can achieve this with one interface.


    Enhanced Receiver Determination in SAP XI - Process Integration - SCN Wiki


    Regards,

    Praveen.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.