Can we use select query in a loop to fetch multiple rows in
a COBOL PROGRAM? If so, what is the advantage of cursor?



Can we use select query in a loop to fetch multiple rows in a COBOL PROGRAM? If so, what is the adv..

Answer / hitendra valluri

As per my knowledge if we loop the select query it retrieves the same data untill we explicitly handle the where clause to retrieve the rows. Unlike select CURSOR fetches all the rows and allows the program to process 1 at a time.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More DB2 Interview Questions

When one binds a PACKAGE ( of a plan ) what package information is stored and where it is stored?

3 Answers  


how do you resolve -818 error in db2. where we have to see time stamp token. i said by seeing in load module and plan .is it correct or not. give clear explination for how to see time stamp token

2 Answers   IBM, TRD,


Which catalog tables contain authorization information?

1 Answers  


Q3. How will you fetch duplicate values from a DB2 table?

2 Answers   RBS,


How to find the number of rows in db2 tables?

0 Answers  


what is consistency token

3 Answers  


List out the three types of page locks that can be held.

0 Answers  


Plan is an executable form of sql statements,But what exactly resides inside a Plan. what are the details inside Plan.

2 Answers   IBM,


Generally if I want to select the names starting with c I need to use c% But how could I code to select the data which contains % as a part of data.

5 Answers  


5 rows are inserted to a DB2 Table. Next 3 of those are updated, then a rollback is issued. What would happen when the rollback is issued?

2 Answers  


What is check constraint. Explain with example.

0 Answers  


Give the name of some fields form sqlca.

0 Answers  


Categories