Is This Content Helpful?
We're glad to know this article was helpful.
When a DBMSCURSOR is declared on a Sybase or AS400 table using the syntax:
Arc: dbmscursor test declare as400 select * from dbms_table for update of dbms_column
the following message is returned:
No unique index found
Cannot be updated
Unlike other supported DBMSs, Sybase and the AS400 do not support the concept of a unique row-id. Therefore, there must be a unique index on the table in order for the cursor to be declared.
Create a unique index on the table before the cursor is declared. For the procedure on how to create a unique index, consult the DBMS's reference manual.
The general SQL syntax for creating a unique index is as following:
Arc: dbmsexecute as400 create unique index ~ on table_name(the_unique_column_name_goes_here)