Arrays Used in Batch Processing (Technical)

In Absence Management batch processing, arrays are used to store data. Arrays are temporary tables that COBOL programs use to store data during processing. Once processing is complete, the programs write the data from the temporary arrays to the appropriate output tables.

Occasionally you might need to modify the COBOL programs to accommodate a larger maximum array size than is defined in the programs that are delivered by PeopleSoft. If an array is too small (the data overflows the array), you get an error message, and the batch process fails. The error message (MSGID-ARRAY-OFLOW) identifies the array and the COBOL file where the array is defined. This guides you to the location in the designated file that might need modification.

Increasing the Occurs Count in Arrays

The table access programs allocate a specified, limited amount of memory space to store in a table array all the details of the absence management process tables that are typical for an absence run.

You can increase the maximum size of an array by increasing the occurs count in the appropriate table access program.

Note:

This is the only COBOL modification that we detail because COBOL modifications to the delivered Absence Management programs are strongly discouraged.

For example, let’s look at a piece of unmodified code in GPCDPDM.CBL.

Below is an array and its related COUNT control field that prevents the program from aborting. When you make a modification, both highlighted numbers must be changed and kept in sync.

05  L-PMT-COUNT           PIC 9999    VALUE 0   COMP.
         88  L-PMT-COUNT-MAX               VALUE 20.
05  L-PMT-DATA                        OCCURS 20
                                           INDEXED BY PMT-IDX.

The assumption here is that there will never be more than 20 absences processed for a payee during any calendar run. If more than 20 absences were processed, the program would issue an error message (MSGID-ARRAY-OFLOW), and the absence management process would terminate.

While the system loads and refreshes this array once for each payee, the system refreshes other arrays for each absence, and loads and increments others throughout the entire process.

This type of modification is not difficult to deal with when you upgrade to a new Absence Management release, when PeopleSoft delivers a whole new set of source code. Simply move your array size modifications to the new code line. Whenever you change the size of an array, be sure to recompile the entire Global Payroll COBOL code line (GPP*).