Thanks Kolusu.

I was wondering if there's a way to terminate the matching process as soon
as it find the first unmatched record.

Your approach stops the read of the output file of the matching process
(after it tried to match each and every record - which is redundant - I only
wanted to know if the data sets were identical, and the first record, for
example, did not match and I could have just stopped there).

Hope I'm making myself clear.

Thanks again,
Yifat

-----Original Message-----
From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On
Behalf Of Sri h Kolusu
Sent: Wednesday, November 07, 2012 12:42 AM
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: Data Set Comparison Using Sort

Yifat,

With DFSORT, you can use STOPAFT=1 on the maintask instead of reading all
the joined/unpaired records.

Sample control cards

//STEP0100 EXEC PGM=SORT 
//SYSOUT   DD SYSOUT=* 
//INA      DD DISP=SHR,DSN=Your Input File1
//INB      DD DISP=SHR,DSN=Your Input File2
//SORTOUT  DD SYSOUT=* 
//SYSIN    DD * 
  JOINKEYS F1=INA,FIELDS=(1,5,A)
  JOINKEYS F2=INB,FIELDS=(1,5,A)
  JOIN UNPAIRED,F1,ONLY
  OPTION COPY,STOPAFT=1
//*

Thanks,
Kolusu
DFSORT Development
IBM Corporation

IBM Mainframe Discussion List <IBM-MAIN@listserv.ua.edu> wrote on
11/05/2012 06:07:46 AM:

> From: Yifat Oren <yi...@tmachine.com>
> To: IBM-MAIN@listserv.ua.edu,
> Date: 11/05/2012 06:12 AM
> Subject: Data Set Comparison Using Sort Sent by: IBM Mainframe 
> Discussion List <IBM-MAIN@listserv.ua.edu>
> 
> Hello,
> 
> I'm doing a Data set comparison using JOINKEYS statements.
> 
> I'm trying to find a way to stop the Sort as soon as it finds the 
> first non-matching (UNPAIRED) record - that is, we've determined the 
> data sets
are
> not identical - no need to keep matching records.
> 
> Something like STOPAFT=1 but for the output data set.
> 
> The only solution I could come up with was writing an E35 exit for 
> UNPAIRED,ONLY run that will end with RC=16 as soon as it gets called.
> 
> Is there a more elegant possibility?
> 
> Thanks,
> Yifat Oren
> 
> 
> 
> ----------------------------------------------------------------------
> For IBM-MAIN subscribe / signoff / archive access instructions, send 
> email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
> 

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions, send email
to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to