[Migrated content. Thread originally posted on 01 November 2011]
Using the same syntax as the sample in the manual. However when I go to update, I get "The cursor is READ ONLY".Doing this to read the record.
EXEC SQL
DECLARE COBCUR1 CURSOR FOR
SELECT C_FIRST_NAME, C_LAST_NAME, C_CITY
FROM CUSTOMER
WHERE C_LAST_NAME = KEY-PASSED
FOR UPDATE
END-EXEC.
EXEC SQL
OPEN COBCUR1
END-EXEC.
EXEC SQL
FETCH COBCUR1
INTO :C-FIRST-NAME,
:C-LAST-NAME,
:C-CITY
END-EXEC
Then after user makes changes, I do the following.
EXEC SQL
UPDATE CUSTOMER SET
C_FIRST_NAME = :C-FIRST-NAME,
C_LAST_NAME = :C-LAST-NAME,
C_CITY = :C-CITY
WHERE CURRENT OF COBCUR1
END-EXEC
Then I get message "The cursor is READ ONLY"
In the config file I have the setting
ACUSQL_ODBC_CURSORS 0
Any ideas anyone?
Patty
