Neal Eckhardt wrote on ibm-main:
>A user has asked if ICETOOL can compare two datasets and provide the
>records that exist in file 2 that are not in file 1.
>
>SO, if file1 is
>
>1
>2
>3
>4
>5
>
>and file2 is
>
>1
>2
>3
>4
>6
>
>the resulting file would contain
>
>6
>
>I don't think it can, but I thought I'd ask anyway.
Sure it can. Here's a DFSORT/ICETOOL job that will do what you asked for.
I assumed your input files have RECFM=FB and LRECL=80, but the job can
be changed appropriately for other attributes.
//S1 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN1 DD DSN=... input file1 (FB/80)
//IN2 DD DSN=... input file2 (FB/80)
//T1 DD DSN=&&T1,UNIT=SYSDA,SPACE=(CYL,(5,5)),DISP=(MOD,PASS)
//OUT DD DSN=... output file (FB/80)
//TOOLIN DD *
COPY FROM(IN1) TO(T1) USING(CTL1)
COPY FROM(IN2) TO(T1) USING(CTL2)
SELECT FROM(T1) TO(OUT) ON(1,1,CH) NODUPS USING(CTL3)
/*
//CTL1CNTL DD *
INREC OVERLAY=(81:C'1')
/*
//CTL2CNTL DD *
INREC OVERLAY=(81:C'2')
/*
//CTL3CNTL DD *
OUTFIL FNAMES=OUT,INCLUDE=(81,1,CH,EQ,C'2'),
BUILD=(1,80)
/*
For complete information on all of the things you can do with DFSORT's
ICETOOL, see:
http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA20/6.0?DT=20060615185603
Frank Yaeger - DFSORT Development Team (IBM) - ***@us.ibm.com
Specialties: PARSE, JFY, SQZ, ICETOOL, IFTHEN, OVERLAY, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort/
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to ***@bama.ua.edu with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html