ESQL/C and ESQL/COBOL usage

SQL DECLARE syntax in ESQL/C and ESQL/COBOL has been extended to include the RELEASE_LOCKS_ON_CLOSE keyword:

EXEC SQL DECLARE cursor_name 
	[SEMI_SENSITIVE | INSENSITIVE] 
	[SCROLL | NOSCROLL] 
	[RELEASE_LOCKS_ON_CLOSE]
	CURSOR FOR “select stmt”
	[for {read only | update [ of column_name_list]}]

You cannot use RELEASE_LOCKS_ON_CLOSE with an UPDATE clause except in this form:

EXEC SQL declare cursor c1 release_locks_on_close
   cursor for select * from T for update of col_a

In this case, RELEASE_LOCKS_ON_CLOSE is ignored.

cpre and cobpre cannot generate these ct_cursor() options:

ESQL/C sample code is available in example8.cp; ESQL/COBOL sample code is available in example7.pco.