Documentation >
MAC-PAC Technical Library >
Distribution >
Electronic Data Interchange >
Programs >
EDI Acknowledgment Update - Purpose
EDI Acknowledgment Update - Purpose
ED100E
The EDI Acknowledgment Update program (ED100E) receives transactions (ANSI #855) previously translated by an external EDI translation package. The key fields received through the EDI interface are: Purchase Order Number, Vendor Sales Order Number, External Company/Warehouse, External Bill-to Customer, External Ship-to Customer, Part Number, Order Quantity, Extended Price, and Promised Ship Date.
The program validates the transactions and:
· If valid, updates the promised date on the purchase order release. For direct shipments, it also updates the promised ship date on the sales order if the purchase order line is directly tied to the sales order line. It then deletes the transaction from workfiles (ED100AP1 and ED120AP2). This program only updates the promised ship date on purchase orders and sales orders. It does not update any other information that might be different on the inbound acknowledgment from the purchase order.
· If invalid, writes an error message to the EDI Purchase Order Acknowledgment Error file (ED100AP3). It sets the error status field on the workfiles to either header error or line error and retains the transaction on the appropriate workfiles.
This program can be run in either asynchronous or batch mode. If the program is called in batch mode, it reads through the EDI Purchase Order Acknowledgment Request file (ED300AP) and processes the requested records from the transaction files.
The fields of the EDI Purchase Order Acknowledgment Header file are validated. The external information fields (Company/Warehouse, Bill-to Customer, and Ship-to Customer) are used to find the vendor on the Vendor Master file using the logical file APMASTL9. The purchase order being updated is retrieved using the Purchase Order Number of the Header file. If the purchase order is found, validation is performed.
If no errors occurred, the purchase order is logically locked. The Sales Order Number of the Purchase Order Header file is used to retrieve the most recent release associated with the sales order. If it is found and is not in use, the sales order is locked.
If all acknowledgment header fields are valid, all detail transactions associated with this header are retrieved and read sequentially from the EDI Purchase Order Acknowledgment Detail file (ED100AP2). The fields from the transaction file are then validated. For every detail transaction, the Purchase Order Line (from PO180M2) and the Purchase Order Release for this line (from PO180M3) are retrieved and validated.
If all fields are valid, the promised date (PDPMDT) on the Purchase Order Release record is updated with the date (ADPSDT) from the Purchase Order Acknowledgment Detail file. The sales order line (from OP100M2) is retrieved by using the Sales Order Number, Sales Order Release, and Sales Order Line Number fields from the purchase order line. Key fields are validated. For direct distribution shipments, the promised ship date (SLPRDT) is updated with the date (ADPSDT) from the Purchase Order Acknowledgment file. If an error is found on a sales order, the Purchase Order is updated.
If an error occurred during the validation of a detail transaction, this transaction is rejected and all associated error messages are written to the PO Acknowledgment Error file. However, if the next detail transaction is for the same header and it is valid, the Purchase Order (and possibly the associated Sales Order) is updated.
Key information from the Purchase Order Acknowledgment files is compared to both the purchase order and sales order. Three reports are produced:
· EDI Purchase Order Acknowledgment Update/Warning Control report (ED100A)
· EDI Purchase Order Acknowledgment Update/Warning report (ED100B)
· EDI Purchase Order Acknowledgment Update Errors report (ED100C)