I have dataset DS1 which has records say
1
2
3
4
5
...
...
etc
And also I have second dataset DS2 whcih has records
1
3
4
5
6
8
..
...
Both the files are sorted and now I want to compare these files and write it into the third files if the records are matching.
Answer Posted / harsha
Use following JCL
//STEP010 EXEC PGM=ICETOOL
//SYSOUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//FILEIN DD DSN=XXXXXXXXXXXXXX,DISP=SHR
//TOOLIN DD *
SELECT FROM(FILEIN) TO(UNIQFL) -
ON(1,73,CH) NODUPS
SELECT FROM(FILEIN) TO(DUPFL) -
ON(1,73,CH) ALLDUPS
/*
//*
//DUPFL DD SYSOUT=*
//UNIQFL DD SYSOUT=*
//*
Label DUPFL will show all duplicate records
Label UNIQFL will show all unique records
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
What is an in line perform? When would you use it? Anything else you wish to say about it.
Define cobol?
Name the divisions, which are available in a cobol program?
I have to write to a outfile where the number of records in that file should be the header of that file using IMS.. can anyone help me in this issue
how do you reference the ksds vsam file formats from cobol programs
What is the difference between structured cobol programming and object alternativelyiented cobol?
Name some of the examples of COBOl 11?
How to find out the closest prime number of an input number? I believe it has something to do with SEARCH and COBOL Linear Array.
what is amode(24), amode(31), rmode(24) and rmode(any)?
How do get the result of your program directly on your pc?
What is inspect in cobol ?
What is the LINKAGE SECTION used in COBOL?
What are the different types of condition in cobol and write their forms.
How many bytes S(8) comp field occupy and its maximum value?
Write down the divisions of cobol program?