View previous topic :: View next topic
|
Author |
Message |
raviprabhu
New User
Joined: 20 Oct 2006 Posts: 29
|
|
|
|
Is the Multiple start and read for KSDS VSAM in COBOL program is recommendable ?
If not whats the reason ? |
|
Back to top |
|
|
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
During the multiple START (assuming ACCESS IS DYNAMIC), are you reading the same record? If not, then read each record independently and randomly.
But, the worse thing you could do, would be to issue many CLOSE and OPEN's, for whatever reason. |
|
Back to top |
|
|
raviprabhu
New User
Joined: 20 Oct 2006 Posts: 29
|
|
|
|
I have 5 records - I have read all records and then again i need to read from 1st record to 5th record, I am using start and then read (without closing the fie)
Is this fine to do ?
My requirement is for reading multiple times same 5 records |
|
Back to top |
|
|
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
Instead of re-reading the five records over and over, when you read them the first time, place them in a a WS array/table (with an occurs 5) and then upon the next need for them, obtain each one from the array. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Why does someone believe you need to re-read these records?
With only 5 records, suggest you do as Mr. Bil recommended. |
|
Back to top |
|
|
|