Skip to main content

Problem:

Using Net Express Version 40 OpenESQL interface:

What to do to get locked records similar to COBOL's locked records using ISAM files?

Resolution:

Firstly, you should turn on the SQL(DBMAN=ODBC) compiler directive:

IDE: Project -> Properties -> SQL Directives...

This ODBC interface has a wide range regarding the use of relational databases, if you are using Microsoft's SQL SERVER you should add the TARGETDB=MSSQLSERVER option as well.

To control a CURSOR behavior you should set the SET CONCURRENCY LOCKCC option to get locked rows after a FETCH.

This option should be set by default unless the ESQLVERSION option is set to 2.0, then the default should be set to OPTCC (optimistic).

Old KB# 6892