Mapping the Header Section

In this section:

The BIG segment represents the beginning segment of the invoice.

Expand the 810 node and the BIG segment node. The BIG segment contains four elements, which will be mapped.

  1. Map the following @IF function to the _01_Date element:
    @IF(INVOIC02/IDOC/E1EDK02/QUALF == '009',INVOIC02/IDOC/E1EDK02/DATUM,'')

  2. Map the following @IF function to the _02_Invoice_Number element:
    @IF(INVOIC02/IDOC/E1EDK02/QUALF == '009',INVOIC02/IDOC/E1EDK02/BELNR,'')

  3. Map the following @IF function to the _03_Date element:
    @IF(INVOIC02/IDOC/E1EDK02/QUALF == '001',INVOIC02/IDOC/E1EDK02/DATUM,'')

  4. Map the following @IF function to the _04_Purchase_Order element:
    @IF(INVOIC02/IDOC/E1EDK02/QUALF == '001',INVOIC02/IDOC/E1EDK02/BELNR,'')

  5. Set the looping property for the BIG segment to False.

    Your iWay Transformer interface should resemble the following:


Top of page

x
Currency Segment (CUR)

The CUR segment transmits the currency the invoice is billed in. There are two elements used that are constants.

  1. Map the BY constant to CUR01.
  2. Map the USD constant to CUR02.

Top of page

x
Reference Information Segment (REF)

There are two REF segments used in this Transform project. You will need to add the second by selecting the first one, copying it, and pasting it on the 810 node as a sub-tree.

  1. Right-click the first instance of the REF segment and select Copy from the context menu.

  2. Right-click the _810 segment node and select Paste Output, followed by Sub-tree.

  3. Use the Move Up option to position the new REF segment under the first REF segment.

    Now you will need to map values from the IDoc to both REF segments.

  4. Map IA (Internal Vendor Number) to REF01.
  5. Map the VendorNumber from the IDoc to REF02.
  6. Map DP (Internal Vendor Number) to REF01.
  7. Map the Department from the IDoc to REF02.

    Your iWay Transformer interface should resemble the following:


Top of page

x
Name Loops

There are two Name loops used in this Transform project. One is used for the Supplier and the other is used for the Ship-To Address. To accomplish this, you will need to create a second SG0 in the same way you created the additional REF segment. Simply copy the SG0 node and paste it as a sub-tree over the existing _810 segment. You will then use the Move Up option to position the new SG0 node under the first SG0 node.

You are now ready to start mapping to the N1, N3, and N4 segments inside the SG0 nodes.

  1. Map a constant of SU to the N101 segment indicating the Supplier.
  2. Map the UPPERCASE value of the Name to the N102 segment.
    @UPPER(INVOIC02/IDOC/E1EDKA1/NAME1)

  3. Map the Qualifier for the DUNS number "9" as a constant to the N103 segment. Then map the supplier DUNS number as a constant to the N104 segment.
  4. Map the UPPERCASE of the Address values to the N301 and N302 segments.

  5. Map the UPPERCASE value of the City to the N401 segment, then the State to the N402 segment.

  6. Map the ZIP to the N403 segment.

  7. Set the properties for the SG0 node.

    Your iWay Transformer interface should resemble the following:

  8. Map the Ship-To Address to the other occurrence of the SG0 node.
  9. Map the constant ST to the N101 segment.
  10. Map the UPPERCASE value to the Name and map to the N102 segment.

  11. Map the constant UL to the N103 qualifier of the N104 segment.
  12. Map the Name4 to the N104 segment.

  13. Map the IDoc City value to the N301 segment.

  14. Map the IDoc State value to the N302 segment.

  15. Map the City to the N401 segment.

  16. Map the State to the N402 segment.

  17. Map the ZIP to the N403 segment.

  18. Set the properties for this SG0 node.

    Your iWay Transformer interface should resemble the following:


Top of page

x
Terms of Sale Segment (ITD)

There is one ITD segment that is used in this Transform project and must be configured.

  1. Set the looping property for the ITD segment to False.

  2. Map the terms and the terms dates.
  3. Based on the qualifier, map the ITD01 segment.
     @IF(INVOIC02/IDOC/E1EDKA1/IDDAT == '001','08','')

  4. Map the ITD02 segment.
    @IF(INVOIC02/IDOC/E1EDK03/IDDAT == '001','3','')

  5. Map to the ITD03 segment.
    @IF(INVOIC02/IDOC/E1EDK03/IDDAT == '001',@LEFT(INVOIC02/IDOC/E1EDK18/PRZNT),'4'),'')

  6. Map the ITD05 segment.
    @IF(INVOIC02/IDOC/E1EDK03/IDDAT == '001',' INVOIC02/IDOC/E1EDK18/TAGE','')

  7. Map the ITD07 segment.
    @IF(INVOIC02/IDOC/E1EDK03/IDDAT == '002',' INVOIC02/IDOC/E1EDK18/TAGE','')

    Your iWay Transformer interface should resemble the following:


Top of page

x
Date/Time Segment (DTM)

There is one DTM segment that is used in this Transform project and must be configured.

  1. Set the looping property for the DTM segment to Auto.

  2. Map the Qualifier for the terms date to the DTM01 segment if the terms date exists.
    @IF(INVOIC02/IDOC/E1EDK03/DATUM > '0',' INVOIC02/IDOC/E1EDK03/IDDAT ','')

  3. Map the date into the DTM02 segment.

    Your iWay Transformer interface should resemble the following:


iWay Software