Page 1 of 1

Need help regarding this sort.

PostPosted: Wed Oct 15, 2014 7:11 pm
by karthikbuchi
My requirement is like this.

I have 2 files, one item file and another vsam update file.
I have to check the item no from item file and compare it with vsam file.
If that item is not present then I have to add that record in vsam file with item no and cost as zeroes.
How to do this using sort?

Scenario:

first run

item file:
itemno remaining records
111111
222222

vsam file:
itemno cost
111111 13434
222222 24345

now for the next run

Assume there is new item added in
item file:
itemno remaining records
111111
222222
333333

So now my vsam file should be like
vsam file:
itemno cost
111111 13434
222222 24345
333333 00000(shld add cost as zero for new record)