Skip to Content

EDI 856 - Arranging MEA and REF segments

Hello all,

Greetings!

I am working on an outbound EDI 856 scenario where ECC is sending data to 3rd party system. Everything is working fine except for one of the requirement from 3rd party regarding arrangement of 2 segments in the EDI file.

As can be seen in the below screenshot, we have segments MEA and REF under header HL.

In standard EDI format, they get populated as they are getting populated here:

Now, the client's requirement is to have a logic in place so as to populate MEA and REF segments as follows:

S_MEA

S_REF

S_MEA

S_REF

S_MEA

S_REF

Kindly note, the 1st MEA segment belongs to 1st REF segment and so on. There may be multiple MEA and REF segments and they are not limited to 3 as shown in above example.

Looking forward to your kind inputs.

Best regards,

Aman

856-2.jpg (51.6 kB)
856-1.jpg (38.0 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • avatar image
    Former Member
    Jul 19, 2017 at 04:59 AM

    Just for my information are you doing this in SAP? or in anyother middleware.

    Add comment
    10|10000 characters needed characters exceeded

  • Jul 19, 2017 at 06:00 AM

    Aman,

    Create a intermediate structure where your S_MEA and S_REF are under one node like :

    S_INT

    ---------S_MEA

    ----------S_REF

    Then later in mapping you can handle this like repeating the S_INT multiple times with having each node once like.

    S_INT

    --------S_MEA

    --------S_REF

    S_INT

    --------S_MEA

    --------S_REF

    Once this is done you can remove this intermediate structure using node deception concept (you will get blogs on this give it a search) and finally get into your required structure.

    This is bit long task i agree but just had this thought on mind, however not sure this can be done via xslt as don't have much exp in XSLT.

    Br,

    Manoj

    Add comment
    10|10000 characters needed characters exceeded