Don't get lost: Training » Quick Start Guide » Sample Integrations » Sage 300: Intercompany Processing Automation - Setup » Intercompany Processing Automation - ShipmentT

3. Shipment to Receipt

Inter-company Processing: SAMINC O/E SHIPMENT to SAMLTD P/O RECEIPT (SAMACCINTCOIMP)

The second integration necessary for this process performs the return transaction by creating a P/O Receipt in SAMLTD whenever a shipment is raised against an intercompany order within SAMINC.

Both companies MUST be set up in Sage300. See 1. Company setup if this has not yet been done.

The sequence for the integration is identical to the previous sample, except:

  1. Instead of querying SAMLTD for Intercompany Orders, the query is performed against SAMINC for Intercompany Shipments.
  2. Where Orders were created in SAMINC previously, here Receipts are created in SAMLTD instead.

Create Shipment for Intercompany Order in SAMINC

Create a shipment in SAMINC for the intercompany order created previously. To test that the quantities are correctly updated in the receipt, don’t ship all, set them to be less than originally ordered.

The flow of integration:

  1. Read
  2. Hierarchy
  3. Map
  4. Connector
  5. Filter
  6. Second Map
  7. Database Write

Read Transform

The Read transform extracts the intercompany shipments.

Hierarchy Transform

Transforms a flat dataset into a hierarchical one.

Map Transform

Add a single empty field to the dataset to allow the auto-generated receipt number to be captured and then reported on the Audit Report.

Sage300 Connector

In this step we map the dataset onto the SAMLTD P/O Receipt transaction.

  1. On the Field Mapping tab, the P/O Receipt Header is mapped. In order to identify which purchase order to create a receipt for, the PONUMBER field from O/E Shipment is set to the Purchase Order Number field of the receipt which is identical to the way a receipt is created in Sage300.

  1. The Details are then mapped to the Receipt Lines.
  2. To be able to identify and match which line to update within the receipt the POLINENUM field (the POLINE optional field) is mapped to the Purchase Order Line Sequence field.
  3. To set the receipted quantity the Shipment Quantity field (QTYSHIPPED) is mapped to the Quantity Received field.

  1. If the import is successful the RCPNUMBER should be populated:

  1. The corresponding Receipt is SAMLTD should have the Description and Reference populated with the O/E Order and O/E Shipment numbers from SAMINC respectively and the Quantities for the two lines should be populated with the quantities as per the shipment.

Filter, Second Map & DataBase Write

The next three steps write back to the SAMINC O/E Shipment transaction to flag the EXPORTED optional field from False to True, to prevent it from being re-exported.

The logic in these steps is identical to the 2. Purchase Order and will not be explained here.