Master Mainframe Technologies - COBOL, JCL, DB2, VSAM, CICS & More
ABEND Codes SQLCODEs File Status Interview Prep Contact
← Back to SQLCODE Reference
Error

SQLCODE -504

Cursor not declared

Explanation

Referenced cursor was not declared.

Solution

Add DECLARE CURSOR statement, check cursor name spelling.

Example

OPEN MY_CURSOR -- but DECLARE MY-CURSOR used