Outbound

For outbound processing, the process decision tree is as follows:

No GLN

This is the existing functionality. Vendor assigned account number will be used, GLNs will not be used.

  1. account number = lookup tpid_O_SHIPTO
  2. write N1ST - N1^ST^^91^account number

L1_O_USE_GLN = B

Both vendor assigned account numbers and GLNs will be used. If a GLN does not exist in the interface file, a substitution lookup will be performed using the appropriate Lawson ID value to get the matching GLN.

  1. account number = lookup tpid_O_SHIPTO
  2. write N1ST - N1^ST^^91^account number
  3. ship to_GLN
    1. if no ship to_GLN,
      1. ship to_GLN = lookup L1_SHIPTO_GLN with ship to location.
    2. if shipto_GLN,
      1. if N1ST segment exists write N1^DA^^UL^ship to_GLN
      2. if N1ST segment does not exist write N1^ST^^UL^ship to_GLN
  4. company_GLN
    1. if no company_GLN,
      1. company_GLN = lookup L1_COMPANY_GLN with company location.
    2. if company_GLN,
      1. write N1^BT^^UL^company_GLN

  5. vendor_GLN

    1. if no vendor_GLN

      1. vendor_GLN = lookup L1_VENDOR_GLN with vendor location.

    2. if vendor_GLN,

      1. i. write N1^VN^^UL^vendor_GLN

  6. purch from_GLN

    1. if no purch from_GLN,

      1. purch from_GLN = lookup L1_PURCHFROM_GLN with purch from location.

    2. if purch from_GLN

      1. write N1^SE^^UL^purchfrom_GLN

L1_O_USE_GLN = L

Vendor assigned account numbers will not be used. Substitution lookups will be performed using the appropriate Lawson ID value to get the matching GLN.

  1. shipto_GLN

    1. if no ship to_GLN,

      1. ship to_GLN = lookup L1_SHIPTO_GLN with ship to location.

    2. if ship to_GLN,

      1. write N1^ST^^UL^ship to _GLN

  2. company_GLN

    1. if no company_GLN,

      1. company_GLN = lookup L1_COMPANY_GLN with company location.

    2. if company_GLN,

      1. write N1^BT^^UL^company_GLN

  3. vendor_GLN

    1. if no vendor_GLN

      1. vendor_GLN = lookup L1_VENDOR_GLN with vendor location.

    2. if vendor_GLN,

      1. write N1^VN^^UL^vendor_GLN

  4. purch from_GLN

    1. if no purch from_GLN,

      1. purch from_GLN = lookup L1_PURCHFROM_GLN with purch from location.

    2. if purch from_GLN

      1. write N1^SE^^UL^purch from_GLN

L1_I_USE_GLN = O

With this option, GLNs are directly mapped to the ASC X12 file. No lookups are performed. No Lawson ID values will be mapped.

L1_O_USE_GLN = B or L or O

  1. if ship to_GLN

    1. if there is an N1^ST^^91^account_number, write N1^DA^^UL^ship to_GLN

    2. else write N1^ST^^UL^ship to_GLN

  2. if company_GLN, write N1^BT^^UL^company_GLN

  3. if vendor_GLN, write N1^VN^^UL^vendor_GLN

  4. if purch from_GLN, write N1^SE^^UL^purch from_GLN