Program Status Codes
Program Status Codes
Any code placed in the subfield location *STATUS that is greater than 99 is considered to be an exception/error condition. When the status code is greater than 99; the error indicator — if specified in positions 73 and 74 — is set on, or the %ERROR built-in function — if the ‘E’ extender is specified — is set to return ‘1’, or control passes to the appropriate ON-ERROR group within a MONITOR block; otherwise, the program exception/error subroutine receives control. Location *STATUS is updated when an exception/error occurs.
The %STATUS built-in function returns the most recent value set for the program or file status.
The following codes are placed in the subfield location *STATUS for the program status data structure:
Normal Codes
Code : Condition
00000 : No exception/error occurred
00001 : Called program returned with the LR indicator on.
00050 : Conversion resulted in substitution.
Exception/Error Codes
Code : Condition
00100 : Value out of range for string operation
00101 : Negative square root
00102 : Divide by zero
00103 : An intermediate result is not large enough to contain the result.
00104 : Float underflow. An intermediate value is too small to be contained in the intermediate result field.
00105 : Invalid characters in character to numeric conversion functions.
00112 : Invalid Date, Time or Timestamp value.
00113 : Date overflow or underflow. (For example, when the result of a Date calculation results in a number greater than *HIVAL or less than *LOVAL.)
00114 : Date mapping errors, where a Date is mapped from a 4-character year to a 2-character year, and the date range is not 1940-2039.
00115 : Variable-length field has a current length that is not valid.
00120 : Table or array out of sequence.
00121 : Array index not valid
00122 : OCCUR outside of range
00123 : Reset attempted during initialization step of program
00124 : The number of elements for the varying-dimension array is not valid
00125 : The string operand is not valid.
00126 : An error occurred while sending a message.
00202 : Called program or procedure failed; halt indicator (H1 through H9) not on
00211 : Error calling program or procedure
00222 : Pointer or parameter error
00231 : Called program or procedure returned with halt indicator on
00232 : Halt indicator on in this program
00233 : Halt indicator on when RETURN operation run
00299 : RPG IV formatted dump failed
00301 : Class or method not found for a method call, or error in method call.
00302 : Error while converting a Java™ array to an RPG parameter on entry to a Java native method.
00303 : Error converting RPG parameter to Java array on exit from an RPG native method.
00304 : Error converting RPG parameter to Java array in preparation for a Java method call.
00305 : Error converting Java array to RPG parameter or return value after a Java method.
00306 : Error converting RPG return value to Java array.
00333 : Error on DSPLY operation
00351 : Error parsing XML document
00352 : Invalid option for %XML
00353 : XML document does not match RPG variable
00354 : Error preparing for XML parsing
00355 : The program or procedure is not available for the DATA-GEN or DATA-INTO operation
00356 : The document for the DATA-INTO operation does not match the RPG variable
00356 : The document for the DATA-INTO operation does not match the RPG variable
00357 : The parser for the DATA-INTO operation detected an error
00358 : The information supplied by the parser for the DATA-INTO operation was in error
00359 : An error occurred while running the program or procedure for the DATA-INTO or DATA-GEN operation
00361 : An error occurred preparing the data from the RPG variable for the generator for DATA-GEN
00362 : The information supplied by the generator for the DATA-GEN operation was in error
00363 : The generator for the DATA-GEN operation detected an error
00364 : An error occurred while handling the output file or output variable for the DATA-GEN operation
00365 : An error occurred with the sequence of DATA-GEN operations
00401 : Data area specified on IN/OUT not found
00402 : *PDA not valid for non-prestart job
00411 : Data area type or length does not match
00412 : Data area not locked for output
00413 : Error on IN/OUT operation
00414 : User not authorized to use data area
00415 : User not authorized to change data area
00421 : Error on UNLOCK operation
00425 : Length requested for storage allocation is out of range
00426 : Error encountered during storage management operation
00431 : Data area previously locked by another program
00432 : Data area locked by program in the same process
00450 : Character field not entirely enclosed by shift-out and shift-in characters
00451 : Conversion between two CCSIDs is not supported
00452 : Some characters could not be converted between two CCSIDs
00453 : An error occurred during conversion between two CCSIDs
00501 : Failure to retrieve sort sequence.
00502 : Failure to convert sort sequence.
00802 : Commitment control not active.
00803 : Rollback operation failed.
00804 : Error occurred on COMMIT operation
00805 : Error occurred on ROLBK operation
00907 : Decimal data error (digit or sign not valid)
00970 : The level number of the compiler used to generate the program does not agree with the level number of the RPG IV run-time subroutines.
09998 : Internal failure in ILE RPG compiler or in run-time subroutines
09999 : Exception message received by procedure.