The Calculation process returns an “Error Code 153 Subscript out of range (in PAPCCMFN.cbl, line 1998)” message after PUM update.
Root Cause
After applying a PUM update, a custom Mortality Rate set was not correctly retained or restored. There were no Mortality Rate entries for the referenced Mortality Rate set. The Calculation failed abruptly with a 153 – Subscript Out of Range error.
Solutions
Restoring the Mortality Rate set entries resolved the issue.
Datamover can migrate custom Mortality Tables and Rates from a reliable source to the upgrade instance.
Run DMS in Production Instance to Export Custom Mortality Table/Rates:
-- Export from reliable Source
-- Update below with Custom Mortality Table name(s).
SET OUTPUT c:\TEMP\Export_Mort.DAT;
SET LOG c:\TEMP\Export_Mort.LOG;
EXPORT PA_MORT_TABLES WHERE MORT_TABLE_NAME = 'RPA2000';
EXPORT PA_MORT_RATES WHERE MORT_TABLE_NAME = 'RPA2000';
Export DMSRun DMS in Upgrade Instance to Import Custom Mortality Table/Rates:
-- Import to upgraded instance
-- Update below with Custom Mortality Table name(s).
SET INPUT c:\TEMP\Export_Mort.DAT;
SET LOG c:\TEMP\Import_Mort.LOG;
SET UPDATE_DUPS;
DELETE FROM PS_PA_MORT_TABLES WHERE MORT_TABLE_NAME = 'RPA2000';
DELETE FROM PS_PA_MORT_RATES WHERE MORT_TABLE_NAME = 'RPA2000';
--
IMPORT PA_MORT_TABLES;
IMPORT PA_MORT_RATES;
Import DMSPAPCCMFN.cbl should return a user-friendly error message when no rates are retrieved. At a minimum, PAPCCMFN.cbl should test MORTALITY-RATE array bounds and return a user-friendly error message when exceeded.
Details
Object Code error : file '/mnt/psft_share/psoft/ps_cust_home/HRDEVT/cblbin/PAPCCMFN.gnt'
error code: 153, pc=0, call=1, seg=0
153 Subscript out of range (in PAPCCMFN.cbl, line 1998)
Application TracePrograms: PAPCCMFN
Section: GI000-CHECK-SUB-MINIMUM-AGES
******************************************************************
* *
GI000-CHECK-SUB-MINIMUM-AGES SECTION.
GI000.
* *
* if the age-offset causes the first effective age to be *
* greater than 1, fill the rows from 1 to the first effective *
* with a rate of 0.0000.
******************************************************************
IF EFFECTIVE-AGE > 1
PERFORM VARYING KNTR FROM 1 BY 1
UNTIL KNTR >= EFFECTIVE-AGE
MOVE 0.0000 TO MORTALITY-RATE(LIFE-SUB,
COL-SUB, KNTR)
IF TRACE-THIS-PGM
MOVE MORTALITY-RATE (LIFE-SUB,COL-SUB,KNTR)
TO AUDIT-DISPL-FLD (1)
MOVE KNTR TO AUDIT-DISPL-FLD (2)
STRING 'MORT RATE FOR EFFECTIVE AGE OF '
AUDIT-DISPL-FLD (2) ' FOR '
DISPL-VAL (LIFE-SUB, COL-SUB) ' = '
AUDIT-DISPL-FLD (1)
DELIMITED BY SIZE
INTO PA-AUDIT-TXT OF AUDIT-INFO OF UAUDT
CALL 'PAPUAUDT' USING COPY PACUSING.
END-IF
END-PERFORM
END-IF
.
CHECK-SUB-MIN-AGES-EXIT. EXIT.
******************************************************************
PAPCCMFN COBOLWhen the Trace Actuarial Calculations is selected, the application trace file includes output showing 0.000000 mortality rates inserted up to the effective age of 5000. The “Subscript out of range” error is returned when the array is finally exceeded.
CALLING COMMUTATION MODULE....
BENEFICIARY FACTORS WILL BE PRODUCED
ASSUMPTION SET ID S_RP2K_AA BEING LOADED
...
MORT RATE FOR EFFECTIVE AGE OF 4992.000000 FOR BNFC/TBL2 = 0.000000
MORT RATE FOR EFFECTIVE AGE OF 4993.000000 FOR BNFC/TBL2 = 0.000000
MORT RATE FOR EFFECTIVE AGE OF 4994.000000 FOR BNFC/TBL2 = 0.000000
MORT RATE FOR EFFECTIVE AGE OF 4995.000000 FOR BNFC/TBL2 = 0.000000
MORT RATE FOR EFFECTIVE AGE OF 4996.000000 FOR BNFC/TBL2 = 0.000000
MORT RATE FOR EFFECTIVE AGE OF 4997.000000 FOR BNFC/TBL2 = 0.000000
MORT RATE FOR EFFECTIVE AGE OF 4998.000000 FOR BNFC/TBL2 = 0.000000
MORT RATE FOR EFFECTIVE AGE OF 4999.000000 FOR BNFC/TBL2 = 0.000000
MORT RATE FOR EFFECTIVE AGE OF 5000.000000 FOR BNFC/TBL2 = 0.000000
Application TraceThe Application Trace file does not directly display the Mortality Table used, but
Return Message – Mortality Rates Missing
Here is a starting point for adding better error handling when no mortality rates are found.
Message Catalog Entry for New Error Message
New Message Pointer in PACUMSGP
03 S-MSG-POINTER PIC 9(09) COMP VALUE 0.
88 S-MSG-NO-MSG-SET VALUE 0.
88 S-MSG-NON-NUMERIC VALUE 27000.
. . .
******************************************************************
* CORE-CT Issue 26849 08/12/2024 MWT - Mark Tomsheck, PSPA Tech *
* Return Error Message when Mortality Rates *
* are missing (after a PUM Update). *
* *
88 S-MSG-NO-MORTALITY-RATES VALUE 30020.
* CORE-CT Issue 26849 08/12/2024 MWT - End Changes. *
******************************************************************
PACUMSGP.cblAdd Error Handling Logic to PAPCCMFN
This code returns the new error message and stops processing the employee when no Mortality Rates data is retrieved.
******************************************************************
* *
GA000-LOAD-MORTALITY SECTION.
GA000.
* *
* FETCHES REQUESTED MORTALITY TABLE AND FILLS SPECIFIED *
* MORTALITY COLUMN WITH RATES (qX) *
* *
******************************************************************
INITIALIZE END-OF-MORTALITY-FETCH
PERFORM GC000-SET-AGE-OFFSET-SIGN
PERFORM GE000-FETCH-MORTALITY-ROW
******************************************************************
* CORE-CT Issue 26849 08/12/2024 MWT - Mark Tomsheck, PSPA Tech *
* Return Error Message when Mortality Rates *
* are missing (after a PUM Update). *
* *
IF END-OF-MORTALITY-FETCH-YES
SET W-ERROR-FOUND TO TRUE
SET S-MSG-STD-MSG TO TRUE
SET S-MSG-C-END-CALC TO TRUE
MOVE TABLE-NAME OF BIND-DATA OF S-PAMORTL TO MESSAGE-PARM (1)
SET S-MSG-NO-MORTALITY-RATES TO TRUE
MOVE 'GA000-LOAD-MORTALITY' TO S-MSG-PGM-PARA
PERFORM ZZ000-ERROR-RTN
ELSE
* CORE-CT Issue 26849 08/12/2024 MWT - End Changes. *
******************************************************************
PERFORM GG000-CHECK-NEGATIVE-AGES
PERFORM GI000-CHECK-SUB-MINIMUM-AGES
PERFORM GK000-LOAD-THE-RATES
PERFORM GM000-CHECK-SUPER-MAXIMUM-AGES
******************************************************************
* CORE-CT Issue 26849 08/12/2024 MWT - Mark Tomsheck, PSPA Tech *
* Return Error Message when Mortality Rates *
* are missing (after a PUM Update). *
* *
END-IF
* CORE-CT Issue 26849 08/12/2024 MWT - End Changes. *
******************************************************************
.
LOAD-MORTALITY-EXIT. EXIT.
PAPCCMFN.cblError Message Returned
> 2024-08-29-14.12.10.860000 ERROR IN PGM:(16005,30020) PI(603) Program(PAPCCMFN) Mortality Rates Missing for RPA2000
Application Trace OutputConditions
Referenced Mortality Rate Data Does Not Exist
The Array error is encountered when the referenced Mortality Rates are missing.
Leave a Reply
You must be logged in to post a comment.