what is the difference between declaring the cursor in WS
section and Procedure division?



what is the difference between declaring the cursor in WS section and Procedure division?..

Answer / madhavi chava

As definition of cursor is non executable statement, it is
advisable not to define in procedure division as it may
misunderstood others.

we can define it any where only thing you have to take care
is definition of cursor should be prior to the OPEN
statement of the same cursor.

Is This Answer Correct ?    18 Yes 1 No

Post New Answer

More DB2 Interview Questions

Could you please let me no the query for below I have table name xyx under this there is column name called employee name which starts from 100th column ends 120th column,now i want to replace only column from 101 to 104 which contains ABCS to replace with PQRS for all records which comes beetween 101 to 104 ..how to write query for this..

1 Answers   HSBC,


How can you do the explain of a dynamic sql statement?

0 Answers  


How to resolve -917 sql code in DB2?

3 Answers   Cap Gemini,


Where are plans stored?

2 Answers  


What is the role of union all and union

0 Answers  






What is a clustering index?

2 Answers  


I understand Join always perform better than subqueries. Then what is the advantage/use of Subqueries/correlated subqueries etc.,in DB2 programming.Please explain.

0 Answers  


Is it Possible to declare or create a cursor for UPDATE of table? If yes tell me how? If no Tell me why?

1 Answers   IBM, scintel,


What will the COMMIT accomplish?

5 Answers  


I need to view the number of tables existing under one particular Owner. Is it possible? If so, pl give the SQL query for this?

2 Answers  


how to identify the pseudo conversation by seeing the program

2 Answers   DELL,


How to resolve deadlock issue

5 Answers   IBM,


Categories