The above JCl compares 2 files. 1 file being the base file. And the other one being the new one. Creates one file with all new insertions.
Creates another file with all deletions.
I should not have any deletions normally. Hence I need to abend the job, if there are any records in the dataset which holds deleted
records.
I know I have an option to count the number of records in a dataset and then if the count is more than 0, make it abend. But dont know
the syntax..
Can someone let me know who I should write the next step, so that if there are any records in the <dataset with deletes> the job would abend.
Joined: 18 Nov 2006 Posts: 3156 Location: Tucson AZ
murali922 wrote:
Can someone let me know who I should write the next step, so that if there are any records in the <dataset with deletes> the job would abend.
Have you looked at Smart DFSORT Tricks and the chapter entitled Set RC=12 or RC=4 if file is empty, has more than n records, etc?
I'm not sure, but you might be able to incorporate the technique in the sort that does the splitting.
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
Here's the question I have:
Do you use the DFSORT option as shown, but still have the follow-up job step that causes the abend to occur? Or, do you just incorporate both processes into a single user-written program?