Specifying run cycles with offsets

Four processing cycles are required to schedule the Paymore system:
  • Daily processing-Monday to Friday
  • Weekly processing-Thursday
  • Monthly processing-third Thursday of the month
  • Yearly processing-third Thursday in July

It is easiest to implement these using rules, but this section shows how you can use offsets instead.

Assume that the calendar specifies Monday to Friday as work days, and public holidays are specified as free days. The PAYROLL system requires three period definitions; one cyclic and two noncyclic. Although monthly processing is required on the third Thursday of the month, you should specify the first Thursday as the period origin, because this ensures that you get maximum benefit from the period definition. When the period is created with an origin of the first Thursday, you can easily specify offsets to select the second, third, fourth, or last Thursday of the month.

Periods should not be created for individual business systems; instead, a period should have a processing cycle that can be used by any run cycle in your applications database. Noncyclic periods incur a yearly overhead when you must enter the origin dates for the following year. For this reason you should make the definition as flexible as possible.

Period definitions required for offset examples shows the period definitions that you need, if you specify the Paymore run cycles using periods with offsets.

Table 1. Period definitions required for offset examples
Name Type Origin dates
WEEK All-days cyclic 970102 with an interval of 007 days
FIRSTTHU Noncyclic 970102 970206 970306 970403 970501 and so on
FSTTHU7 Noncyclic 970703