What is a cursor?

Answers were Sorted based on User's Feedback



What is a cursor?..

Answer / guest

A cursor is a programming device that is used to handle the
rows that are returned by the query as the host language
(cobol) can handle only one row at a time. its also a small
file that has the result set. The cursor has to be
declared,opened, fetched and closed to access the data
returnee by the query.

Is This Answer Correct ?    2 Yes 0 No

What is a cursor?..

Answer / vinod babu bachina

In DB2 cursor is used to fetch more than one row from a DB2
table. But cursor can fetch only one row at a time. Suppose
if ur retrieving more than one row from table , u have to
use cursor only. If u use SELECT instead of cursor then it
leads to error '' more than one row selected in select'.

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More DB2 Interview Questions

What is the use of db2?

0 Answers  


In which column of which DB2 catalog would you find the length of the rows for all tables?

2 Answers  


What is a plan and package in db2?

0 Answers  


What is bind in db2?

0 Answers  


How do you eliminate duplicate values in db2?

0 Answers  


What is RUNSTATS?

3 Answers  


select distinct(empid),distinct(dept),name from EMP will the above query work?

2 Answers   CTS,


What is difference between rollback and commit?

0 Answers  


What statistic will tell the DBA how must space can be reclaimed from dropped table spaces on the next reorg run?

1 Answers  


Which DB2 catalog tables are used to produce a list of table column by table for all tables in a database?

1 Answers  


What is host variable in db2 cobol?

0 Answers  


What is the latest version of ibm db2?

0 Answers  


Categories