I have a subprogram B calling from mainprogram A.I have
opened a cursor in A ,Can i fetch the same cursor in
subprogram B , If yes , Please explain the reason?



I have a subprogram B calling from mainprogram A.I have opened a cursor in A ,Can i fetch the same..

Answer / harsha

I feel yes, we can fetch the same cursor in the same
program.
Cursor can be closed in three ways.
1 When you explicitely close trhe cursor.
2 Issuing commit systement.
3 After execution of an application program.

In our situation, none of the above mentioned case is
getting true.

Is This Answer Correct ?    11 Yes 2 No

Post New Answer

More DB2 Interview Questions

What is a view? Why use it?

2 Answers  


How do you leave the cursor open after issuing a COMMIT? (for DB2 2.3 or above only)

2 Answers  


what is SMP/E? and what are the major steps of it? thanks...

1 Answers   IBM,


what is consistency token

3 Answers  


can I alter a table (e.g. adding a column) when other user is selecting some columns or updating some columns from the same table?

1 Answers  


What is CHECK PENDING ?

5 Answers  


how can you copy records present in a flat physical file to a database file(physical file).please explain in rpg400 with a simple example

1 Answers   CTS,


What is IMAGECOPY ?

6 Answers  


What happens to a cursor after a commit?

3 Answers  


What is usage pointer in cobol?

3 Answers   IBM,


Hi Team, Please tell me, If i don't declare the cursor in the program and i have given open and fetch and close, then what error will get.

6 Answers   IBM,


what's the error code for Unique Index Violation?

2 Answers  


Categories