Suppose if I need to update a column, how you do that using
cursor?

Answers were Sorted based on User's Feedback



Suppose if I need to update a column, how you do that using cursor?..

Answer / bobby

continuation of previous answer,

after cursor declaration, open the cursor and fetch the cursor. When the condition for update is satisified isue EXEC SQL UPDATE CURRENT OF.

Is This Answer Correct ?    6 Yes 0 No

Suppose if I need to update a column, how you do that using cursor?..

Answer / sandy

EXEC SQL DECLARE X CURSOR FOR
SELECT * FROM ABC
FOR UPDATE OF <COLUMN> ==>If we know the column we would
like to update.

Is This Answer Correct ?    4 Yes 0 No

Post New Answer

More DB2 Interview Questions

What does db2 blu stand for?

0 Answers  


How to design maps

1 Answers   Virtusa,


What is the purpose of rollback and commit?

0 Answers  


1. what if null values retrived from database and no null indicator mentioned in query. What is sql code.

1 Answers   Cap Gemini,


What does db2 stand for?

0 Answers  






When would you prefer to use VARCHAR?

3 Answers  


List out the data types available.

0 Answers  


When is the access path determined for dynamic SQL?

2 Answers  


One program calling 5 subprograms, its a cobol db2 program, after precompilation how many plans and packages will created?

3 Answers  


How can the firstname and the lastname from the emp table be concatenated to generate complete names?

0 Answers  


Which component is responsible for processing sql statements and selecting access paths?

0 Answers  


Define sqlca.

0 Answers  


Categories