Documentation >
MAC-PAC Technical Library >
Financial >
Accounts Receivable >
Programs >
Data Base Audit/Purge - Purpose >
Data Base Audit/Purge - Calculations
Data Base Audit/Purge - Calculations
AR770P
A. Mainline
System Processing Option. This reference file record (category 133) contains the SSD Flag used to determine if SSD extract field needs to be referenced from shipment/returns logicals (IC190BL2, IC190BL3).
1. Date Format Record
This Reference File record (category 049) contains the date format flag used to determine the date format on the reports.
2. Closed Item Purge Date
This Reference File record (category 335) contains the default purge date. It is used if the purge function is selected but no cutoff date was submitted.
3. Report Options
This Reference File record (category P43) is checked to see if year-end processing is to be performed.
4. Aging Periods
This Reference File record (category P44) contains the aging period days for the system. It is used to determine the first period considered past-due for accumulating customer past-due amounts.
5. Accounts Receivable Transactions
For all records that are read, the following amounts are accumulated from the lower-level files and compared to the amounts on the higher-level files. If any amounts are not equal, error messages are printed on the Data Base Audit/Purge-- Data Base Errors report.
Open item header-level accumulators are:
a. Original gross. Total of all distribution and value added tax amounts from open item distributions for the open item.
b. Original currency original gross. Total of all original currency distribution and value added tax amounts from open item distributions for the open item.
c. Open gross. For open items that are not cash sales, the calculated original gross less the total posted amount from corresponding payment applications for the open item.
d. Original currency open gross. For open items that are not cash sales, the calculated original currency original gross less the original currency total posted amount from corresponding payment applications for the open item.
e. Discount taken. Total of all discounts taken from payment applications to the open item.
f. Original currency discount taken. Total of all original currency discounts taken from payment applications to the open item.
g. Distributions item count. Total number of distribution records for the open item.
h. Open item quantity. Total of all open item quantities from open item distributions for the open item.
Payment header-level accumulators are:
a. Payment amount. Total of all payment amounts applied from payment applications for the payment.
b. Original currency payment amount. Total of all original currency payment amounts applied from payment applications for the payment.
c. Discount taken. Total of all discounts taken from payment applications for the payment.
d. Original currency discount taken. Total of all original currency discounts taken from payment applications for the payment.
e. Write-off. Total of all write-off amounts from payment applications for the payment.
f. Original currency write-off. Total of all original currency write-off amounts from payment applications for the payment.
g. Amount posted. Total of all total payment posted amounts from payment applications for the payment.
h. Original currency amount posted. Total of all original currency total payment posted amounts from payment applications for the payment.
Customer level-accumulators are:
a. Accounts receivable balance. Original gross from open item headers less amount posted from payment headers for the customer.
b. Original currency accounts receivable balance. Original currency original gross from open item headers less original currency amount posted from payment headers for the customer.
c. On-account balance. Total of all on-account unapplied amounts from payment headers for the customer.
d. Original currency on-account balance. Total of all original currency on-account unapplied amounts from payment headers for the customer.
e. Future account age. Total of all open gross amounts from open item headers that fall into the future aging category for the customer.
f. Original currency future account age. Total of all original currency open gross amounts for open item headers that fall into the future aging category for the customer.
g. Period 1 account age. Total of all open gross amounts from open item headers that fall into the period 1 aging category for the customer.
h. Original currency period 1 account age. Total of all original currency open gross amounts from open item headers that fall into the period 1 aging category for the customer.
i. Period 2 account age. Total of all open gross amounts from open item headers that fall into the period 2 aging category for the customer.
j. Original currency period 2 account age. Total of all original currency open gross amounts from open item headers that fall into the period 2 aging category for the customer.
k. Period 3 account age. Total of all open gross amounts from open item headers that fall into the period 3 aging category for the customer.
l. Original currency period 3 account age. Total of all original currency open gross amounts from open item headers that fall into the period 3 aging category for the customer.
m. Period 4 account age. Total of all open gross amounts from open item headers that fall into the period 4 aging category for the customer.
n. Original currency period 4 account age. Total of all original currency open gross amounts from open item headers that fall into the period 4 aging category for the customer.
o. Current account age. Total of all open gross amounts from open item headers that fall into the current aging category for the customer.
p. Original currency current account age. Total of all original currency open gross amounts from open item headers that fall into the current aging category for the customer.
q. Past-due balance. Total of all open gross amounts from open item headers that fall into aging categories considered past-due for the customer.
r. Original currency past-due balance. Total of all original currency open gross amounts from open item headers that fall into aging categories considered past-due for the customer.
s. Original unpaid draft balance. Total of unapplied draft amounts from Draft Master file.
If a customer error occurred, but no errors occurred with its corresponding open items or payments, the customer accumulators on the customer record are updated. This is done because the low-level totals of the open items and payments were correct, but the customer master-level totals were not.
If the Data Base Purge Option was selected, records with balances reduced to zero, with no data base errors, and with a date before the cutoff date are physically deleted.
6. Control Breaks
L1 - Open Item or Payment Control Break
An L1 control break indicates a change in company, location, and document/payment type and number. Audit/purge of the appropriate transaction is performed at this point.
L2 - Customer Control Break
An L2 control break indicates a change in customer number. Audit/purge of the customer is performed at this point.
LR - End of Processing
When an LR control break occurs, the file control records are audited.
7. VAT Registration Number Record
If a Bill-to customer is deleted, then all records on AR635M linked to that Bill-to customer are deleted prior to that deletion.