For update of a row in cursors, when do we move value into
host variable in cobol progrm? is it before open or before
fetch ?

Answers were Sorted based on User's Feedback



For update of a row in cursors, when do we move value into host variable in cobol progrm? is it be..

Answer / azharuddinsyed

in Open, the sql query you have coded in declare cursor will be executed.
in Fetch, the table column values will be moved to corresponding host variables.

Is This Answer Correct ?    0 Yes 0 No

For update of a row in cursors, when do we move value into host variable in cobol progrm? is it be..

Answer / tarun

The query in a cursor in executed only when the cursor is opened. Thus you have to move the values in the host variables before opening the cursor.

Is This Answer Correct ?    8 Yes 17 No

Post New Answer

More DB2 Interview Questions

What is a base table?

2 Answers  


For a db2 column that is being defined as decimal (11, 2), discuss the cobol picture clause.

0 Answers  


What is a Resource Control Table(RCT)? Describe its characteristics.

3 Answers  


What happens to the PLAN if index used by it is dropped?

1 Answers  


What are packages in db2?

0 Answers  






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

0 Answers  


Q1. How will you use two different DB2 qualifiers in a single COBOL program? Suppose we have 2 tables EMP1 and EMP2 with same structure defined in two different DB2 qualifiers QUAL1.EMP1 and QUAL2.EMP2 now during first 15 days we want to use QUAL1.EMP1 and rest of the days QUAL2.EMP2  how will we do this.  We can create a single program and a single load for this program. 

2 Answers   RBS,


How is deadlock resolved?

0 Answers  


What is a db2 collection?

0 Answers  


db2 maintains information about the data... a.in tables. b.in a set of tables known as db2 catalog. c.in db2 database. d.none of the above.

1 Answers  


How can you find out which query is taking lot of time to execute in cobol-db2 program ?

1 Answers   Danske,


in GDG: is it poosible to copy records from a file which utilizes some 100 cylinders to a gdg whose model is defined as trk(1,0) and also it possible to copy 100 bytes file to 80 bytes file?

1 Answers   IBM,


Categories