Franchise Return Purge (wf_returns_purge_job)
Module Name |
wf_returns_purge_job |
Description |
Franchise Return Purge |
Functional Area |
Franchise Management |
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.
Thread assignment program will filter eligible records from franchise returns header table based on its conditions are met and number of days elapsed as defined by system parameter setting, Franchise History Months:
-
All the billing records associated with the franchise order are not yet extracted or where not enough time has elapsed since they were extracted as defined by the system parameter setting.
-
All transfers associated with the franchise order were purged through their respective purge process.
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 delete the records from franchise returns header and other related franchise return tables. 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 18-4 Key Tables Affected
Table | Select | Insert | Update | Delete |
---|---|---|---|---|
PERIOD |
Yes |
No |
No |
No |
SYSTEM_OPTIONS |
Yes |
No |
No |
No |
RMS_BATCH_STATUS |
Yes |
No |
No |
No |
B8D_PROCESS_CONFIG |
Yes |
No |
No |
No |
JOB_AUDIT_LOGS |
No |
Yes |
No |
No |
B8D_WF_RETURNS_PURGE_STG |
Yes |
Yes |
No |
Yes |
WF_RETURN_HEAD |
Yes |
No |
No |
Yes |
WF_RETURN_DETAIL |
No |
No |
No |
Yes |
WF_BILLING_RETURNS |
Yes |
No |
No |
Yes |
TSFHEAD |
Yes |
No |
No |
No |