View previous topic :: View next topic
|
Author |
Message |
virumf
New User
Joined: 07 May 2007 Posts: 6 Location: bangalore
|
|
|
|
Hi,
can any one help me out in knowing whether processing an input,loading it into vsam is better or reading and input sequential n loading it into an array and then processing it.
Say input has around 500 records,need to do search on that input depending on some criteria,so i thought of going for loading that input into vsam and then it becomes easy for processing in the program.
but there is also another solution like loading that input into an array and then do search on that array...
which is best solution overall...? |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
|
|
Viru,
Quote: |
can any one help me out in knowing |
Only one way, why dont you implement and let us know. |
|
Back to top |
|
|
CICS Guy
Senior Member
Joined: 18 Jul 2007 Posts: 2146 Location: At my coffee table
|
|
|
|
virumf wrote: |
Say input has around 500 records,need to do search on that input depending on some criteria,so i thought of going for loading that input into vsam and then it becomes easy for processing in the program.
but there is also another solution like loading that input into an array and then do search on that array...
which is best solution overall...? |
It all depends, but for a small amount of data (500?) that currently does not have any VSAM structure, I'd lean towards the array.... |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello Virumf and wlecome to the forums,
What do you consider "better"? |
|
Back to top |
|
|
virumf
New User
Joined: 07 May 2007 Posts: 6 Location: bangalore
|
|
|
|
Hi,
Thnx for replies..
here "better" i mean perfromance wise and also i/o overheads..
look forward to more feedback from you all |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Well, if you use the array, there should be no additional i/o.
If you use the array efficiently (SEARCH ALL) and do not perform the search when not needed (the "thing" you are are about to search for is the "thing" you last searched for), it will not take so much cpu time.
If the array needs to be updated as you go, this further reduces resources needed if vsam is used.
From what has been posted, i'd suggest the array. |
|
Back to top |
|
|
|