Configuring Order Level Segments

How to:

The following sections describe how to map the order level segments.


Top of page

x
Procedure: How to Configure the HL (Hierarchy) Elements
  1. Under the SG0 tag, which is located under inv_order, right-click the HL tag, select Add, and then click Element.

  2. Repeat step 1 to create another element.
  3. Use the position icons (Move Up and Move Down) on the toolbar (or right-click and select from the control menu) to position one of the newly created elements at the top of all HL elements, and the other at the bottom of all HL elements.
  4. Rename the top HL element as incr_hlctr and the other element at the bottom, save_location_of_order, as shown in the following image.

  5. Right-click the incr_hlctr element, select Properties in the context menu, click the ellipses (...) button under the General tab, and then map the HLCTR variable.
  6. Select ADD in the action, then set the constant value to 1.

  7. Map the HLCTR variable to the HL01 element, located in HL, under SG0 after expanding inv_order, and select GET as the action.

  8. Map the LEVEL1 variable to the HL02 element and set the action to GET.

  9. Expand inv_order, SG0, and then HL, and map the constant O to HL03.
  10. Map the LEVEL2 variable to the save_location_of_order element and set the GET current value to HLCTR (@VARIABLE(HLCTR,GET)).


Top of page

x
Procedure: How to Configure the PRF (PO Number) Elements
  1. Add a hidden group node (OUTPUT_GROUP_NODE) above the PRF element and move the PRF element into the new group.
  2. Set the looping to false.
  3. Set the context to the following:
    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDK02

  4. Click the Filter tab.
  5. Enter the following in the Condition field:
    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDK02/QUALF == '001'

  6. Configure the mapping values for the PRF elements as indicated by the following table:

    Element

    Value

    PRF01

    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDK02/BELNR

    PRF04

    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDK02/DATUM

    Your screen should now resemble the following image:


Top of page

x
Procedure: How to Configure the REF DP (Department) Elements
  1. Add a hidden group node and move the PRF segment into it.
  2. Set the looping to false.
  3. Set the context to the following:
    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDKT1

  4. Click the Filter tab.
  5. Enter the following in the Condition field:
    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDKT1/TDID == 'Z002'

  6. Configure the mapping values for the REF elements as indicated by the following table:

    Element

    Value

    REF01

    DP

    REF02

    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDKT1/E1EDKT2/TDLINE

    Your screen should now resemble the following image:


Top of page

x
Procedure: How to Configure the REF MR (Merchandise Type) Element
  1. Copy the group you just mapped.

  2. Highlight SG0 at the top of the order group.
  3. Paste the REF DP element.

  4. Move the group to below the REF DP element.

  5. Change the specified condition in the Filter tab from Z002 to Z003.

  6. Change REF01 from DP to MR. Your screen should now resemble the following image:


Top of page

x
Procedure: How to Configure the REF IA (Internal Vendor Number) Element
  1. Copy the group you just mapped.

  2. Highlight SG0 at the top of the order group.
  3. Paste the REF MR element.

  4. Move the group up until it is located below the REF MR element.

  5. Leave the filter as Z002 which is copied from REF DP.

  6. Set value IA to REF01 and value VENDORID to REF02.

    You have now mapped three of the four required REF segments.


Top of page

x
Procedure: How to Configure the REF IV (Invoice Number) Element
  1. Paste one more REF node and leave it as the last one in the group. Leave the filter set to Z002 and the context set the same as the previous REF elements.
  2. Set value REF01 to IV and map ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/Z1INVOICE/BELNR to REF02. Your screen should now resemble the following image:

    Note that the invoice number is located in ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/Z1INVOICE/BELNR. This field is an extension field to the IDoc. The stock SAP IDoc for the ASN does not contain the invoice number. This is due to the order of operations in the flow to ship merchandise, as shown in the following diagram.

    The ASN IDoc is usually created as a by-product of the Material Goods Issue Update process. Depending on the shipping system, it might be possible to create the ASN IDoc from the "truck has left" notification from the shipping system to SAP. Invoicing is usually a batch process that runs overnight. In this example, because the trading partner requires the invoice number on the ASN, the Invoicing process is run periodically during the day, either for all customers or just those EDI customers that require the invoice number on the ASN. The invoice number appears in an extension field on the IDoc. The following image is how the flow should now appear.


Top of page

x
Procedure: How to Configure the N1 BY (Buyer) Element
  1. Add a new hidden group tag, and move it up so the new tag is above the SG4 group and below the SG3 group under the SG0 node in inv_order.
  2. Copy the SG4 group to the new group.

  3. Set the context to the following:
    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDKA1

  4. Click the Filter tab.
  5. Enter the following in the Condition field:
    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDKA1/PARVW == Z2

  6. Click OK.

    Your screen should now resemble the following image:

  7. Configure the mapping values for the N1 elements as indicated by the following table.

    Element

    Value

    N101

    BY

    N102

    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDKA1/NAME1

    N103

    UL

    N104

    ZWALASN/IDOC/Z1BILL_DOC/E1EDL20/E1EDK01/E1EDKA1/E1EDKA3/STDPN

    Your screen should now resemble the following image:


iWay Software