Penalty Run

The Penalty Run task calculates penalty amounts and creates penalty transactions for line items that remain unpaid past their delinquency dates.

This task is typically run once a day.

  1. Query for line items that qualify to be penalized.
    Although penalties are applied at the line item level, the penalty run task starts at the account level. So the query first selects accounts that match the parameters entered for the run, then the bills associated with those accounts, and finally the line items associated with those bills. Various tests are applied to determine which line items are eligible for penalties:
    • The account isn’t penalty exempt (ACCOUNT.PENEXEMPT = N)
    • The associated bill isn’t paid (BILL.PAIDSTAT = N)
    • The line item isn’t pending (LINEITEM.PENDTYPE = N)
    • The line item hasn’t been penalized (LINEITEM.PENALIZEDFLAG = N)
    • The bill’s DELINQUENTDATE and the line item’s PENALTYDATE are on or before the current date
    • The amount of the line item is greater than the minimum charge amount for the bill type.

    The run will also include any accounts with final bills, regardless of the parameters that you enter, unless you enter a bill type. If you enter a bill type, then the run will include all accounts with final bills that match that bill type.

  2. Determine amounts to be penalized.

    The amount to be penalized varies depending on the bill type. Some bill types only penalize line items that aren’t paid, and others penalize all line items associated with a bill, both paid and unpaid, if the entire bill isn’t paid. Similarly, some bill types only penalize the unpaid portion of a line item, and others penalize the whole amount. Finally, some bill types also penalize unpaid penalties.

  3. Calculate penalties.

    Penalty amounts are calculated following the rules defined in your penalty tables. They may also be adjusted if necessary based on the minimum and maximum penalty amounts for the bill types.

  4. Save penalties.

Setup

This table describes the Configuration Editor settings that affect this task:

Configuration and pathComments
BatchProcessing/TASKS/Task: PenaltyRun/ThreadsSets the number of asynchronous threads the Batch Manager will use for the Penalty Run process.

The default number of threads for all multithreaded processes is set in the BatchManager configuration’s Number of Task Threads attribute. You only need to enter a separate value here if you want to override the default.

BILLING/BATCHMANAGER/Create Penalty Run Inputs/CommitNumberSpecifies the commit number for all penalty runs. The commit number determines the number of accounts processed in each thread.
Note: You can enter any number, but there are limitations at the database level. Oracle databases have a limit of 1,000 records, and SQL Server databases have a limit of 2,000 records. Entering a larger number will cause errors.
BILLING/BATCHMANAGER/Create Penalty Run Inputs/Create0AmountPenalties Indicates whether the Penalty Run task will create penalties with $0.00 amounts.

This table describes the Infor Public Sector setup forms that are used to configure this task:

Setup formComments
Penalty TableUsed to create penalty tables. Penalty tables define rules for applying penalties to unpaid charges.
Bill TypeUsed to define penalty options for bill types. Most importantly, you can specify the penalty code that will be used to calculate penalties for each bill type. You can also enter minimum and maximum penalty amounts and set options such as whether Infor Public Sector will penalize the full principal amount of a bill even if the bill is partially paid.
Line Item SetupCan be used to associated penalty codes with line items. If a line item has a penalty code, it will override the penalty code on the bill type. To create penalties, you will also require at least one penalty line item.

This table lists the database tables that store setup information for this task:

TableComments
BILLING.ACCOUNTAccounts that are penalty exempt will have the PENEXEMPT column set to Y.
BILLING.BILLTYPEBill type penalty settings are stored in the PENALIZEENTIREBILLFLAG, PENALLFLAG, PENALTYAGEDFLAG, PENALTYCODEKEY, and PENALTYPENFLAG columns.
BILLING.LINEITEMSETUPLine item penalty codes are stored in the PENALTYCODEKEY column.
BILLING.PENALTYCODEStores penalty codes. Each code defines a set of rules for calculating penalties, based on one or more penalty tables. By associating penalty codes with bill types and line items you indicate how those bill types and line items are to be penalized.
BILLING.PENALTYTABLEStores penalty tables. Each table is defined by a penalty code and an effective date, so the penalty table represents the rules for calculating penalties for that code within the effective date range.
BILLING. PENALTYTABLEDETAILStores penalty table details. Each penalty table detail is defined for a selected business object property so that accounts can be penalized differently according to their characteristics. For example, you might define a detail for the account class property so that residential and commercial accounts can be penalized differently.
BILLING. PENALTYTABLEFREQUENCYStores the actual penalty calculation rules for penalty details. Each record in this table is a child of a PENALTYDETAIL record.

Invocation

You can use the Batch Manager or the Billing Calendar to schedule penalty runs. In addition, the Create Penalty Run form can be used to add a new penalty run manually. The Manage Account page can also be used the penalize a single account, and the Bill InfoViewer and Line Item InfoViewer can be used to penalize single bills and line items.

This table describes each parameter for this task:

FormConsoleDescription
Address RouteMeterReadingRoute (int)Address route to use as a selection parameter.
Bill TypeBillType (int)Bill type to use as a selection parameter.
Billing CycleBillingCycle (string)Billing cycle to use as a selection parameter.
Commit IntervalCommitInterval (int)Number of accounts processed in each batch.
Note: You can enter any number, but there are limitations at the database level. Oracle databases have a limit of 1,000 records, and SQL Server databases have a limit of 2,000 records. Entering a larger number will cause errors.
GroupGroup (string)Account group to use as a selection parameter.
SubgroupSubGroup (string)Account subgroup to use as a selection parameter.

Monitoring

If the penalty run is successful, you should see a series of log entries similar to these in the Billing Batch Process log:

  • Penalty Run process started for Penalty Key [key] at: [date/time]
  • Starting pools for the process...
  • LoadLineItemTask:LoadAccounts: Loading Line Items for batch of Accounts.
  • LoadLineItemTask:LoadAccounts [#] Line Items with delinquent balances retrieved successfully satisfying Penalty criteria.
  • PenaltyTask:ProcessPenalties: Started Committing [#] Account(s) to database.
  • PenaltyTask:ProcessPenalties: Finished Committing [#] Account(s) with [#] Exceptions
  • Penalty Run process finished.

In the database, the PROCESSFLAG column in BILLING.PENALTY is set to Y at the start of a run, and set to N when the run is finished. In addition, the STARTDTTM and STOPDTTM columns in the PENALTY table give the date and time the run started and stopped.

Common errors

This table lists some common errors that this task may return:

Error messageComments
Line Item Amount is less than Bill Type Minimum Charge Amount.The minimum charge amount specifies the minimum amount of a line item that Infor Public Sector will penalize.
No Penalty Line Item Setup Key found, so Account Activity record not saved for line item setup [line item] on Bill [bill key]Before you can create penalties in Infor Public Sector, you must create at least one penalty line item in Line Item Setup.

User exceptions

The Penalty Run is one of four batch processes (in addition to Bill Run Schedule, Direct Debit Run, and Post Payments Run) for which you can define your own custom exceptions. Each custom exception you define uses a formula to determine when Infor Public Sector will return the exception. For penalty runs, there are two user exception severity levels:

  • Level 1: Do not process the account.
  • Level 2: Process the account but add an exception record.

Data output

This table lists the database tables in which this task adds or updates records:

Table Comments
BILLING.ACCOUNTACTIVITY An account activity record is added for each penalty so the associated account can be billed.
BILLING.ACCTTRAN The penalty run adds an account transaction for each penalty charge created in the run.
BILLING.LINEITEM Each line item penalized will have its PENALTYDATE and PENALIZEDFLAG columns updated. PENALTYDATE indicates when the line item can next be penalized; PENALIZEDFLAG indicates whether it has reached the maximum penalty.
BILLING.LINEITEMPENALTY Stores penalty information for penalized line items, including the line item key, the account key for the associated account, the penalty amount, and the penalty run key.
BILLING. LINEITEMPENALTYSTAGE Stores calculation details for line item penalties. Each LINEITEMPENALTYSTAGE record is a child of a LINEITEMPENALTY record.
BILLING.PENALTY Stores information on each penalty run, including the run key, the parameters used, the number of accounts penalized, and the number of exceptions.

This table lists the Infor Public Sector forms that you can use to review the results of this task:

Table Comments
Lookup Penalty Run Standard Infor Public Sector lookup used to search for penalty runs.
Penalty Run InfoViewer Shows details on a selected penalty run. You can also reverse a run.