what is the syntax for FOR UPDATE CLAUSE in cursor
declaration and how can u update using cursor? is it
possible to update multiple rows at a time.
Answer Posted / vaneesh khurana
EXEC SQL
DECLARE STUDENT-CSR CURSOR
SLECT NAME, CLASS, MARKS, STATUS
FROM STUDENT-TABLE
WHERE ROLL-NO = :WS-ROLL-NO
FOR UPDATE OF STATUS
END-EXEC
EXEC SQL
UPDATE STUDENT-TABLE SET STATUS =:WS-STATUS
WHERE CURRENT OF STUDENT-CSR
END-EXEC
| Is This Answer Correct ? | 6 Yes | 2 No |
Post New Answer View All Answers
What is the syntax for seeing the columns and data types of a table in the db2 database?
Differentiate between cs and rr isolation levels? Where do you specify them?
What is copy pending and check pending in db2?
How many databases are there?
Explain the function done by data manager?
What is bind and rebind in db2?
Which components manage deadlocks in db2?
What do you mean by between and in? Is between inclusive of specified range values?
What is db2 look?
SQLCODE = -199, ERROR: ILLEGAL USE OF KEYWORD CHAR, TOKEN KEY was expected
What is the result of open cursor statement?
How can tablespace be moved to another dasd volume that is allocated for that tablespace?
What is a bind card?
What is the use of dclgen in db2?
What is table space in db2?