OPTIMIZECURSORS

Optimizes memory consumption when using Oracle, PostgreSQL, DB2 providers. Also applies the same data integrity rules on all databases for embedded SQL cursors that use WITH HOLD and FOR UPDATE clauses for DBMAN=ODBC.

Syntax:

OPTIMIZECURSORS={YES|NO}

Parameters:

YES
Optimize cursors. This can result in considerable memory savings and performance gains for large result sets, and also ensures that SQL cursors that use WITH HOLD and FOR UPDATE clauses have appropriate database locks when positioned updates/deletes occur.
NO
Provided for backward compatibility. Sets the behavior to that of Visual COBOL versions before 3.0.

Properties:

Default: YES

Dependencies:

To use OPTIMIZECURSORS, you must set DBMAN to ODBC explicitly, or by setting an SQL compiler directive option that sets DBMAN to ODBC implicitly.

Scope:

Used at compile time: Yes
Behavior at run time: Source file

See Scope - OpenESQL SQL Compiler Directive Options for more information.