on 07-22-2020 12:11 AM
Dear experts,
I am receiving XML files from a 3rd party.
This is the challenge: these files contain multiple business documents. I have to create ORDCHG (update sales order) and SHPCON (update outbound delivery) IDocs from these, depending on a field in the payload "DELIVERY_NO":
Is this possible? Can I do this using a multi-mapping, I looked at this blog for example: https://blogs.sap.com/2011/02/24/multi-mapping-without-bpm-for-idoc-scenarios-yes-it-s-possible/
But my target message would be 2 different IDoc types, so my structure would look like this:
<?xml version="1.0" encoding="UTF-8"?>
<DELVRY07>
<IDOC BEGIN="1">
...
</DELVRY07>
<ORDERS05>
<IDOC BEGIN="1">
...
</ORDERS05>
I appreciate any input on this. Thank you.
Best regards, Peter
.
Hello,
I solved this not using a multi-mapping but using the EDI Separator. This blog was helpful:
https://blogs.sap.com/2016/11/16/part-2-split-ups-are-hard-using-the-sap-b2b-edi-separator-adapter-f...
Best regards, Peter
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Peter,
You can split the message using condition and execute 2 different mappings. 1 for SHPCON and the other for ORDCHG.
The condition will check the existence of the field delivery no, if that is not blank execute the SHPCON else the ORDCHG.
In case of multiple Order detail segments, you can create a SHPCON and ORDCHG IDoc xsds with 0..unbounded occurrence.
Hope I understood your requirement correctly.
Thanks
Sugata
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Sugata,
this is what I have currently now which works well if I receive a file with DELIVERY_NO filled on all ORDER_DETAIL.
Or with DELIVERY_NO empty on all ORDER_DETAIL
The condition only checks the first occurrence. So if there is a mix the condition is not catching it. So from what I see the split needs to happen in the mapping, correct?
Best regards, Peter
User | Count |
---|---|
87 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.