Cursor not in a valid state

Error constant SQLE_CURSOR_INVALID_STATE
ODBC 2 State 24000
ODBC 3 State 24000
Severity 16
SQLCODE –853
SQLSTATE 24000
Sybase error code 557
Probable cause

You attempted to use a cursor that is not in a valid state for the attempted operation. For example, the cursor may have encountered an error.