Previous Topic: Base CalendarsNext Topic: Schedule Resolution


Perpetual Calendars

Using perpetual calendars can automate the generation of base calendars. When the criteria for building a calendar are defined in the Perpetual Calendar DSN (PCALDSN), the corresponding base calendar (SCALyyxx) is generated and used on the first reference of the calendar if the calendar does not exist. The reference to the calendar could be a PRINT, RESOLV, CALMOD, or any other command or process that needs a calendar.

Perpetual calendars, defined with the member name PCALYYxx, describe scheduling and nonscheduling days in English-like terms. These members can be used each year, because the command that references a calendar builds the SCALyyxx member if it does not already exist. This permits the same set of criteria to be used each time. As a result, perpetual calendars are a tool for jobs that use the same "relative" processing days year after year. For example, a job that executes every Monday, Wednesday, and Friday can reference a perpetual calendar PCALYY3W that has the following statements:

Set all days nonscheduled

Set Mondays Wednesdays Fridays schedule

When a command such as PRINT is used, CA WA CA 7 Edition generates the base calendar SCALyy3W (as an example) that sets the processing days for each Monday, Wednesday, and Friday of each week. This eliminates the need to set up each year the corresponding SCALyy3W.

Note: For more information about perpetual calendars see the Systems Programming Guide.