MAC-PAC Homecontact ussupport login 
Documentation > MAC-PAC Technical Library > Manufacturing > Transfer Control > Programs > Transfer Order Shipping Update - Purpose > Transfer Order Shipping Update - Calculations

Transfer Order Shipping Update - Calculations

TC125E

A.   Housekeeping

1.   Parameter lists are set up for entry, error, and warehouse balance (create records).

2.   Key lists are defined for file retrieval.

3.   Workfields are defined and constants are initialized.

4.   The following information is retrieved from the Reference file (REFERP):

a.   Applications installed (category 012).

b.   Date format codes (category 049).

c.   System defaults (category 133).

d.   Decimal precision (category D89).

e.   Inventory control defaults (category 436).

f.    Quantity field sizes (category 446).

g.   All company/warehouses to which the user is authorized are retrieved from category 409 and loaded into an array.  If no records are found for the user, a flag is set to authorize the user to all company/warehouses.

h.   If this is the first shipment for this order, the in-transit vendor company/warehouse customer number, adjustment code and order class are retrieved from Reference File category D07. If no record exists on category D07, the program ends.  Otherwise, the In-transit company/warehouse, the invoice flag, customer number, and vendor number are updated on the Transfer Order Header file (TC100M1) and processing continues.

i.    Next bill of lading number (category D91)

j.    Lot system defaults (category Y34) 

B.   Mainline

1.   Initial Processing

a.   The Transfer Order Shipping Online program (TC120E) accesses the Transfer Order Shipment Location file (TC120B4W) to ensure that there are records to process.  If no records exist, the program ends. 

b.   Processing continues until all eligible records have been processed.

2.   Begin Processing

a.   The Transfer Order Shipping Update program locks all pertinent files.  The workfile at the workstation level is processed until all eligible records have been processed.

b.   An error occurs if:  one of the required files cannot be locked or if an overflow occurs in a field during an arithmetic operation.  All files are unlocked and a rollback is done to relieve files of calculations performed to the point of error.

3.   Process

a.   If the transfer order shipment is being invoiced, the following information is retrieved:

      1.)        Customer Master and Customer Name and Address records (ARCUSTL1)

      2.)        Receiving warehouse exchange rates from the Currency Master  (CF240M)

      3.)        Default book code (category 135)

      4.)        VAT types (category 024)

      5.)        Company/location defaults (category 132)

      6.)        The customer VAT code and home/export flag are validated.

      7.)        Accrued Receivables account number (category 302)

      8.)        Current sales period calendar (category 407)

      9.)        Last sales period (category 435)

      10.)       Payment terms information (category 323)

b.   All configuration costs are retrieved for configuration costed (PMCFCO = 3 or 4) parts from the Configuration Code file (EC140M).  If no record for that part exists in the sending warehouse or the receiving warehouse, one is created with zero costs.  If a record exists in the sending warehouse but not the receiving warehouse, the costs are copied to the new record.

c.   Totals are accumulated for lines, supplying company/warehouse, in-transit company/warehouse (if not invoicing the shipment) multiple location file, and increase cumulative quantity shipped.  After this processing is complete, the next record is retrieved from the workstation.  The system verifies if the in-transit company/warehouse defined on Reference File category D07 is a distribution warehouse.  If it is not and the in-transit company/warehouse is available for planning, the system uses the balance type defined on Reference File category D07 to receive the inventory.

d.   Totals that were accumulated (by line number 2) stock location, lot number, and balance type) are processed and written  into their respective record formats.

e.   Transaction costs are calculated, including new unit costs and warehouse balances.

f.    If the shipment is being invoiced, transactions are written to the Shipment/Returns Audit Trail file (IC190BP) and to the Sales History (OP120M) and Sales History Discount Detail (OP120M2) files.  If the shipment is not being invoiced, transactions are written to the From and To Stock Transfer Audit Trail files (IC120BP2 and IC120BP3).  The Transfer Order Shipment Location file (TC120BP4) is also updated.

g.   For each transfer order line that is invoiced, records are written to the Pending Invoice Detail file (ARPNDDP) and the Pending Invoice Discount Detail file (ARPNDSP).  Sales account transactions are also written to the Accounting Transaction file (AR510AP) for each shipment line.

h.   A record is written to the Bill of Lading Lot file (OP690AP3) for each line/lot combination.  Each time this is done a record is written to the Bill of Lading Line file (OP690AP2) for each line combination.  When all lines have been processed, a record is written to the Bill of Lading Transaction file (OP690AP1).  If the consolidated Bill of Lading flag is N (No), the next available bill of lading number is retrieved for the appropriate sourcing company/warehouse combination from Reference File category D91 and is assigned to that shipment.  If the Consolidated BOL Flag is N (No), and the BOL release code is not hold then a record is written to the BOL Shipment Transaction Print file (OP690BP2).  Also a record is written either to the BOL Trigger file (OP690BP) if the BOL release code is immediate or to the BOL Print Request file (OP310HP) if the release code is normal. 

i.    Once all processing is complete for a line, the line total is accumulated and end processing is performed.

4.   End Processing

a.   If the shipment is being invoiced, a VAT record is written to the Pending Invoice Detail file (ARPNDDP) and the Accounting Transaction file (AR510AP).  Customer statistics are updated and a record is written to the Pending Invoice Header file (ARPNDOP).  Finally, an Accrued Receivables account record is written to the Accounting Transaction file (AR510AP).

b.   The Transfer Order Shipping Location Work file (TC120B4W) is cleared when all records for a line have been processed.  If the file is empty, the workfile is cleared, the error code and transfer order line are set to blanks, and control is returned to TC120E. 

c.   Control is returned to the online shipping program.

TC125E Program Menu