Write Purchase Order Information to Purchase Order History Tables (order_revision_job)
Module Name |
order_revision_job |
Description |
Write Purchase Order Information to Purchase Order History Tables |
Functional Area |
Purchase Orders |
Module Type |
Admin - Ad hoc |
Module Technology |
Background Processing |
Catalog ID |
N/A |
Wrapper Script |
b8dwrap.ksh |
Design Overview
This background job is composed of two-step processing. It will have a threading assignment and a business logic processing.
Order changes made by the client that may need to be sent to the vendor. The order changes should always be referred to as 'versions' and kept clearly distinct from order 'revisions' which are vendor changes uploaded via the ediupack program.
Thread assignment program will filter eligible records from order revision history and order header tables based on its order status ('A'pproved or 'C'losed) and supplier that exists from supplier table. When orders are approved or when approved orders are modified, this program selects order numbers from the order revision history table. These records are chunked and Thread ID is assigned for each. They will be stored temporarily in a staging table.
The Business logic program will process all records from the staging table. Using bulk processing, this program will writes versions of approved orders and its current order information to the order/allocation revision history tables. After the new version has been written to the order revision tables, all records will be deleted from the order revision history table for that order record. If an order is not in approved status at the time the batch program runs, then none of the above processing will occur. These records will stay on the order revision history table until the PO is approved or deleted. It will free up and clean the staging table afterwards. There is a STOP ON NEXT feature in bulk processing (through a loop) where Administrators can stop this batch with a flip of this indicator.
Key Tables Affected
Table 5-4 Key Tables Affected
Table | Select | Insert | Update | Delete |
---|---|---|---|---|
RMS_BATCH_STATUS |
Yes |
No |
No |
No |
B8D_PROCESS_CONFIG |
Yes |
No |
No |
No |
JOB_AUDIT_LOGS |
No |
Yes |
No |
No |
B8D_ORDER_REVISION_STG |
Yes |
Yes |
No |
Yes |
REV_ORDERS |
Yes |
No |
No |
Yes |
ORDHEAD |
Yes |
No |
Yes |
No |
SUPS |
Yes |
No |
No |
No |
ORDHEAD_REV |
Yes |
Yes |
No |
No |
ORDSKU |
Yes |
No |
No |
No |
ORDLOC |
Yes |
No |
No |
No |
ALLOC_HEADER |
Yes |
No |
No |
No |
ALLOC_DETAIL |
Yes |
No |
No |
No |
ORDSKU_REV |
No |
Yes |
No |
No |
ORDLOC_REV |
No |
Yes |
No |
No |
ALLOC_REV |
No |
Yes |
No |
No |