Reason code (logical errors)

If a logical error occurs and you have no LERAD routine (or the LERAD exit is inactive), VSAM returns control to your program following the last executed instruction. For information on the LERAD routine, see z/OS DFSMS Using Data Sets.

The return code in register 15 indicates a logical error (8), and the RPL feedback area contains a reason code identifying the error. Register 1 points to the RPL.

Some VSAM reason codes for logical errors, used for diagnosis purposes, are shown in z/OS DFSMSdfp Diagnosis.

Table 1 lists the feedback area reason codes and their meanings. Some of these reason codes in the figure use the term LUWID in their meaning column. For a CICS® application, LUWID is a CICS transaction identifier. For a batch job, LUWID is a unique value that RLS assigned to the address space. For DFSMStvs, LUWID is a unique value assigned to each unit of recovery (UR).

Table 1. Logical-error reason codes in the feedback area of the request parameter list. Logical-error reason codes in the feedback area of the request parameter list
Reason code (RPLERRCD) when register 15=8(X'8') Meaning
4(X'4') End of data set found (during sequential or skip sequential retrieval), or the search argument is greater than the high key of the data set. Either no EODAD routine is provided, or one is provided, returned to VSAM, and the processing program issued another GET. (For information on the EODAD routine, see z/OS DFSMS Using Data Sets.)
8(X'8') You attempted to store a record with a duplicate key, or there is a duplicate record for an alternate index with the unique key option.
12(X'C') An attempt was made to perform sequential or skip-sequential processing against a record whose key/record number does not follow the proper ascending/descending sequential order. The error may occur under any one of the following processing conditions:
  • For a key-sequenced data set
    • PUT sequential or skip-sequential processing
    • GET sequential, single-string input only
    • GET skip-sequential processing and the previous request is not a POINT
  • For a relative record data set
    • GET skip-sequential processing
    • PUT skip-sequential processing
16(X'10') Record not found, or the RBA is not found in the buffer pool. (If multiple RPL requests are issued for alternate indexes, getting return code 16(X'10') might mean a temporary situation where processing has not been completed on either the base cluster or the associated alternate indexes.)
20(X'14') Control interval exclusive use conflict. The address of the RPL that owns the resource is placed in the first word in the RPL error message area.
For VSAM RLS and DFSMStvs, another RPL that is used by this LUWID or UR holds an exclusive lock on this record. This code means that there was an intra-LUWID exclusive control conflict. If an RPL message area of sufficient length is specified, the following information is returned.
Offset Length Description
 
0      4      Address of RPL in exclusive control
4      1      Flag Byte: - Not used For RLS
              X'00'--neither RPL doing a control
                     area split
              X'01'--current RPL doing a control
                     area split
              X'02'--other RPL doing a control
                     area split

If this request's RPL specifies a MSGAREA of length 4 bytes or greater, the address of an RPL whose lock on this record caused this request to be rejected is returned in the first 4 bytes of MSGAREA. The application may choose to issue an ENDREQ on that RPL and then reissue this POINT, GET NUP, or GET UPD request.

21(X'15')

For VSAM RLS and DFSMStvs, another LUWID holds an exclusive lock on this record. The combination of one or more LUWIDs waiting for other record locks held by this LUWID and this LUWID waiting for this record lock produced a deadlock.

If an RPL message area of sufficient length (four bytes or longer) is specified, and the requestor is a commit protocol application (for example, CICS), the following information is returned in the RPL message area:
Offset Length Description
 
0      4      Address of problem determination area
              If you see this error, you are required 
              to free this area, for example, with:
              ?STORAGE (RELEASE) where LENGTH=VPDISIZE,
              SP=0,KEY=user's key.
22(X'16')

For VSAM RLS and DFSMStvs, another LUWID holds an exclusive lock on this record. This request waited for the record lock until the timeout interval expired.

If an RPL message area of sufficient length (four bytes or longer) is specified, and the requestor is a commit protocol application (for example, CICS), the following information is returned in the RPL message area:
Offset Length Description
 
0      4      Address of problem determination area.
              If you see this error, you are required 
              to free this area, for example, with:
              ?STORAGE (RELEASE) where LENGTH=VPDISIZE, 
              SP=0,KEY=user's key.
24(X'18') Record resides on a volume that cannot be mounted.

For VSAM RLS and DFSMStvs, another LUWID holds a retained lock on this record. This can occur if the other UR closed the data set with the UR inflight and it was the last close of the data set on the system.

If an RPL message area of sufficient length (four bytes or longer) is specified, the following information is returned in the RPL message area:
Offset Length Description
 
0      4      Address of problem determination area.
              If you see this error, you are required 
              to free this area, for example, with:
              ?STORAGE (RELEASE) where LENGTH=VPDISIZE, 
              SP=0,KEY=user's key.
For non-RLS, message area information is not returned.
28(X'1C') Data set cannot be extended because VSAM cannot allocate additional direct access storage space. Either there is not enough space left to make the secondary allocation request, or you attempted to increase the size of a data set while processing with SHAREOPTIONS=4 and DISP=SHR.

For VSAM RLS and DFSMStvs, the error can occur for a GET request when the same error has been issued for a preceding PUT request on the same ACB.

32(X'20') You specified an RBA that does not give the address of any data record in the data set.
36(X'24') Key ranges were specified for the data set when it was defined, but no range was specified that includes the record to be inserted.
40(X'28') Insufficient virtual storage in your address space to complete the request.
44(X'2C') Work area not large enough for the data record or for the buffer (GET with OPTCD=MVE).
48(X'30') Invalid options, data set attributes, or processing conditions:
  • CNV processing
  • The specified RPL is asynchronous
  • Chained RPLs
  • Path processing
  • Shared resources (LSR/GSR) indeterminate buffer status
  • Load mode
  • Fixed-length relative record data set
  • Data set contains spanned records
  • User not in key 0 and supervisor state
  • End-of-volume in process (secondary allocation).
52(X'34') Invalid options, data set attributes, or processing conditions specified by MVS/DFP™. (See X'34' for a list of the invalid options).
56(X'38') Error from catalog update at the beginning of a CI/CA split for backup while open.

For VSAM RLS and DFSMStvs, this error indicates an invalid reuse of an RLS RPL.

This RPL has position established for VSAM RLS and DFSMStvs access to a data set. The application has changed the ACB or the LUWID, or both. VSAM RLS and DFSMStvs do not permit this form of RPL reuse. This error does not change or lose the string's position. Before changing the ACB or LUWID, the application must issue an ENDREQ on the RPL to release the string's position.

RPL reuse violation. The RPL request had positioning information from a previous request and the ACB or LUWID specified in the RPL, or both, did not match that of the prior request.

64(X'40') There is insufficient storage available to add another string dynamically. Or, the maximum number of place holders that can be allocated to the request has been allocated, and a place holder is not available.

For VSAM RLS and DFSMStvs, the limit of 1024 outstanding requests for this ACB has been exceeded.

68(X'44') The application attempted to use a type of processing (output or control interval processing) that was not specified when the data set was opened.
72(X'48') The application made a keyed request for access to an entry-sequenced data set. Or, the application issued a GETIX or PUTIX to an entry-sequenced data set or fixed-length RRDS.

For VSAM RLS and DFSMStvs, the application issued a GETIX or PUTIX. GETIX and PUTIX are not supported by VSAM RLS and DFSMStvs

76(X'4C') The application issued an addressed or control interval PUT to add to a key-sequenced data set or variable-length RRDS. Or, the application issued a control interval PUT to a fixed-length RRDS.
80(X'50') The application issued an ERASE request in one of the following situations:
  • For access to an entry-sequenced data set
  • For access to an entry-sequenced data set via a path.
  • With control interval access.
84(X'54') The application specified OPTCD=LOC in one of the following situations:
  • For a PUT request.
  • In the previous request parameter list in a chain of request parameter lists.
  • For UBF processing.
88(X'58') The application issued a sequential GET request without being positioned to it. Or, the application changed from addressed access to keyed access without being positioned for keyed-sequential retrieval. No positioning was established for a sequential PUT insert for an RRDS. Or, the application attempted an illegal switch between forward and backward processing.
92(X'5C') The application issued a PUT for update, an ERASE without a previous GET for update, or a PUTIX without a previous GETIX. For DFSMStvs, this can also mean that the application issued a PUT UPD or an ERASE without the GET UPD in the same unit of recovery. This means that if the application did the GET UPD, the application did a commit or a backout before doing the PUT UPD or ERASE.
96(X'60') The application attempted to change the prime key or key of reference while making an update. Or, for MACRF=RLS, the PUT NUP request attempted to change the key that a prior IDALKADD request specified.
100(X'64') The application attempted to change the length of a record while making an addressed update.
104(X'68') The RPL options are either invalid or conflicting in one of the following ways:
  • SKP was specified and either KEY was not specified or BWD was specified.
  • XRBA was not specified in the RPL OPTCD when a GET DIR or a POINT request was issued in ADR or CNV mode with LRD=OFF, and RPLARG points to a nonzero argument (RBA), while processing an extended-addressing data set.
  • BWD was specified for CNV processing.
  • FWD and LRD were specified.
  • Neither ADR, CNV, nor KEY was specified in the RPL.
  • BFRNO is invalid (less than 1 or greater than the number of buffers in the pool).
  • WRTBFR, MRKBFR, or SCHBFR was issued, but either TRANSID was greater than 31 or the shared resource option was not specified.
  • ICI processing was specified, but a request other than a GET or a PUT was issued.
  • MRKBFR MARK=OUT or MARK=RLS was issued but the RPL did not have a data buffer associated with it.
  • The RPL specified WAITX, but the ACB did not specify LSR or GSR.
  • CNV processing is not allowed for compressed data sets. Only VERIFY and VERIFY REFRESH are allowed.
  • VERIFY was specified for a UNIX file.
  • BWD or UPD was specified for a UNIX file.
  • DIR was specified for a UNIX file that is an FIFO or character special file.
  • Non-key access issued against extended-format, extended-addressing data set when RBA/XRBA is required for positioning.
108(X'6C') Incorrect RECLEN. Some possible reasons are:
  1. RECLEN specified was larger than the maximum allowed, equal to 0, or smaller than the sum of the length and the displacement of the key field.
  2. RECLEN was not equal to record (slot) size specified for a fixed-length RRDS.
  3. RECLEN was not sufficient to contain the new alternate index key pointer. With nonunique UPGRADE alternate indexes, the record is automatically increased in size each time a record is added to the base cluster and this can cause an incorrect RECLEN. Make sure the maximum RECORDSIZE on the alternate index is large enough for all base pointers it must contain.
112(X'70') KEYLEN specified was too large or equal to 0.
116(X'74') During initial data set loading (that is, when records are being stored in the data set the first time it is opened), GET, POINT, ERASE, direct PUT, skip-sequential PUT, or PUT with OPTCD=UPD is not allowed. For initial loading of a fixed length RRDS, the request was other than a PUT insert.
120(X'78') Request was operating under an incorrect TCB. For example, an end-of-volume call or a GETMAIN macro was necessary to complete the request, but the request was issued from a task other than the one that opened the data set. The request can be resubmitted from the correct task if the new request reestablishes positioning.
124(X'7C') A request was cancelled for a user JRNAD exit.
128(X'80') A loop exists in the index horizontal pointer chain during index search processing.
132(X'84') An attempt was made in locate mode to retrieve a spanned record.
136(X'88') The application attempted an addressed GET of a spanned record in a key-sequenced data set.
140(X'8C') The spanned record segment update number is inconsistent.
144(X'90') Invalid pointer (no associated base record) in an alternate index.

If multiple RPL requests are issued for alternate indexes, getting return code 144(X'90') might mean a temporary situation where processing has not been completed on either the base cluster or the associated alternate indexes.

For example, you have issued multiple RPL requests including erase requests to the path or base cluster, and got a return code of X'90'. This might be a temporary situation where the base cluster has been erased, but the associated alternate index has not been erased. If you provide a message area using the MSGAREA parameter of the RPL macro, VSAM returns the address of an RPL doing the erase when the return code X'90' was set.

148(X'94') The maximum number of pointers in the alternate index has been exceeded.
152(X'98') Not enough buffers are available to process the application request (shared resources only).
156(X'9C') Invalid control interval detected during keyed processing, an addressed GET UPD request failed because control interval flag was on, or an invalid control interval or index record was detected. The RPL contains the invalid control interval's RBA.
160(X'A0') One or more candidates were found that have a modified buffer marked to be written. The buffer was left in write status with valid contents. With this condition, it is possible to have other buffers invalidated or found under exclusive control.
168(X'A8') For MACRF=RLS, the pointer in the RPL to the record is zero.
180(X'B4') For MACRF=RLS, an invalid request for a nonrecoverable data set.
184(X'B8')

For MACRF=RLS, the application issued an ABEND condition while VSAM was processing this request. The VSAM RLS FRR (Functional Recovery Routine) intercepted the failure and failed the VSAM request with this reason code.

185(X'B9')

For MACRF=RLS, the user task was cancelled while the request was being processed.

186(X'BA') For MACRF=RLS, an abend occurred in an attempt to access user storage during logging. This might have happened if the application program issued FREEMAIN or STORAGE RELEASE for the buffers.
187(X'BB') For MACRF=RLS, an error occurred with partial EOV processing.
188(X'BC')

For MACRF=RLS, the sphere is in lost locks state. A record management request was issued by this SUBSYSNM, but these requests are not allowed until the sphere is out of lost locks state.

189(X'BD')

For MACRF=RLS, a lock for the VSAM request required space in the record table, but the table was full. Installation action is needed to modify the CFRM policy and rebuild the lock structure.

190(X'BE') Partial EOV error.
192(X'C0') Invalid relative record number.
196(X'C4') The application issued an addressed request to a fixed-length or variable-length RRDS.
200(X'C8') The application attempted addressed or control interval access through a path.
204(X'CC') PUT insert requests (or for VSAM RLS or DFSMStvs, IDALKADD requests) are not allowed in backward mode.
205(X'CD') For DFSMStvs, indicates that the request was unable to complete because DFSMStvs restarted while the unit of recovery was inflight. To continue processing, the application must issue a commit or a backout and then begin a new unit of recovery. For LSF, indicates invalid CONTOKEN.
206(X'CE') For DFSMStvs, indicates that the request was rejected because the data set is quiesced or quiescing for copy. Wait for the copy to complete and then retry the request. For NSR, LSR, or GSR, this reason code indicates a validity check error for shareoptions 3,4.
207(X'CF') Indicates that DFSMStvs processing is currently unavailable because DFSMStvs is quiescing or disabling. Close all data sets to allow the quiesce/disable process to complete.
208(X'D0') An ENDREQ was issued against an RPL that has an outstanding WAIT against its associated ACB. No ENDREQ processing was done.
209(X'D1') For DFSMStvs, indicates that the forward recovery log is unavailable because it is disabling. For LSR, indicates cache structure failure.
210(X'D2') For DFSMStvs, indicates that forward recovery logging failed because the record length is greater than the installation-defined maximum for the log. For shared resources, buffer being invalidated, buffer use chain changing, and so on.
211(X'D3') For DFSMStvs, this indicates that the forward recovery log is unusable for this system as a result of either a failure by OPEN to complete connect processing to the logstream, or an error occurred while writing to this logstream. See accompanying DFSMStvs logger messages for appropriate action.

For LSR, the cache request is purged.

212(X'D4') During control area split processing, an existing condition prevents the split of the index record. Index or data control interval size, or both, might need to be increased.
213(X'D5') For DFSMStvs, indicates that the undo log is unavailable for processing. For LSR, no connectivity to the cache structure.
214(X'D6') For DFSMStvs, indicates that a permanent I/O error was detected in the undo log. For appropriate action, see accompanying DFSMStvs logger messages.
216(X'D8') For MACRF=RLS, LUWID specified in the RPL does not exist for the subsystem name specified in the ACB.
217(X'D9') DFSMStvs is unable to complete the request because the resource recovery services (RRS) instance failed and RRS has been restarted. To continue processing, the application must issue a commit or a backout and then begin a new unit of recovery.
218(X'DA') Unrecognizable return code from SVC109.
220(X'DC') DFSMStvs was unable to complete the request because RRS is currently unavailable.
224(X'E0') MRKBFR OUT was issued for a buffer with invalid contents.
228(X'E4') Caller in cross-memory mode is not in supervisor state, or RPL of caller in SRB or cross-memory mode does not specify LSR, GSR, or SYN processing. For MACRF=RLS, the caller is not in primary ASC mode, the caller is in SRB mode, the caller issued a record management request with an FRR in effect, or the task that opened the ACB is not in the caller task hierarchy.
229(X'E5') The record length changed during decompression processing.
230(X'E6') The processing environment was changed by the user of the UPAD exit.
232(X'E8') UPAD error; ECB was not posted by the user in cross-memory mode.
235(X'EB') VSAM RLS or DFSMStvs internal error.
236(X'EC') Validity check error for SHAREOPTIONS 3 or 4.
237(X'ED') Reserved.
238(X'EE') Reserved.
239(X'EF') Reserved.
240(X'F0') For shared resources, one of the following is being performed: (1)an attempt is being made to obtain a buffer in exclusive control, (2)a buffer is being invalidated, or (3)the buffer use chain is changing. For more detailed feedback, reissue the request.
241(X'F1') Reserved.
242(X'F2') Reserved.
243(X'F3') Reserved.
244(X'F4') Register 14 stack size is not large enough.
245(X'F5') Severe error returned by compression management services during a compress call. Additional problem determination is provided in the RPL message area.
246(X'F6') An error occurred during an expansion of the user record for an extended-function data set. The RPL message area contains additional problem determination.
248(X'F8') Register 14 return offset went negative.
249(X'F9') For DFSMStvs, indicates that undo logging failed because the record length is greater than the installation-defined maximum for the log. For LSR XI, invalid vector token.
250(X'FA') No valid dictionary token exists for the data set. VSAM is unable to decompress the data record.
252(X'FC') Record-mode processing is not allowed for a linear data set.
253(X'FD') VERIFY is not a valid function for a linear data set.
254(X'FD') I/O activity on the data set was not quiesced before WRTBFR TYPE=DS was issued.

When the search argument you supply for a POINT or GET request is greater than the highest key in the data set, the reason code in the feedback area depends on the RPL's OPTCD values, as the following table shows.

This tables shows how the reason code in the feedback area depends on the RPL's OPTCD values.
Request type RPLs OPTCD options Reason code when register 15=8(X'8')
POINT GEN,KEQ 16(X'10')
POINT GEN,KGE 4(X'4')
POINT FKS,KEQ 16(X'10')
POINT FKS,KGE 4(X'4')
GET GEN,KEQ,DIR 16(X'10')
GET GEN,KGE,DIR 16(X'10')
GET FKS,KEQ,DIR 16(X'10')
GET FKS,KGE,DIR 16(X'10')
GET GEN,KEQ,SKP 16(X'10')
GET GEN,KGE,SKP 4(X'4')
GET FKS,KEQ,SKP 16(X'10')
GET FKS,KGE,SKP 4(X'4')