Page 1 of 1

Opening DB2 cursor multiple times will affect performance ?

PostPosted: Wed May 25, 2016 8:39 am
by gauthamnagpur18
Hi All,

While analyzing cobol-db2 program of high execution time(5hrs+), found out that same cursor has been opened for 29 times.
We are just changing the policy type each time.
Cursor has simple select query from three tables.
There are total 2.8 Million rows, If we don't put "Where" clause in select query.

I believe opening cursor multiple times is affecting performance.

I am planning to extract via INZUTILB utility and format using COBOL program. For extraction, it just took 4 mins of execution time. I kept all the 29 values in IN predicate of select query.

Before I start formatting the data, I would like to hear from experts is there any other way to reduce execution time?

Thanks in advance.