We use ExecureProcedure() to execute a stored procedure which returns a result set. But we see lot of "Invalid cursor state" errors when the result set is empty. The connection to SQL server database is made through ODBC.
ERROR #6022: Gateway failed: Fetch. + ERROR <Ens>ErrGeneral: SQLState: (24000) NativeError:  Message: [Microsoft][ODBC Driver 11 for SQL Server]Invalid cursor state
Here is the code snippet from the business operation class which uses