I have 2 I/p files
F1 - file 1
Length 187
length 24 -32 & 32 - 40 have ACCT NO ( acc 1 (24-31) & acc 2 ( 32-40) ) 40 - 106 Student Details.
F2 - file 2
Length 187
length 24 -32 & 32 - 40 I have ACCT NO 40 - 106 Student Details.
File 1 should be searched with file 2 using acct 1(24-8) along with 40-102
& it should search with acct 2( 32-40) so record no present with any of acct 1 & 2 should be written to File output.
Please help me to write search
I tried
COPYDIFF
KEY1=(24,8,C)
KEY2=(32,8,C)
but it is not searching Key 2 Search.
Compare 2 files with Multiple Key
Moderators: Frank Yaeger, Moderator Group
- Frank Yaeger
- Moderator
- Posts: 812
- Joined: Sat Feb 18, 2006 5:45 am
- Location: San Jose, CA
- Contact:
Are those COMPAREX control statements? Is that the utility you want to use?
Frank Yaeger - DFSORT Development Team (IBM) - yaeger@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
-
- Member
- Posts: 25
- Joined: Tue Apr 28, 2009 10:53 pm
- Location: USA
- Contact:
tamilthangam,
If you have access to SyncSort for z/OS, here is a job that should produce your desired output:
If you have access to SyncSort for z/OS, here is a job that should produce your desired output:
Code: Select all
//STEP1 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTJNF1 DD DSN=input.file1,...
//SORTJFN2 DD DSN=input.file2,...
//SORTOUT DD DSN=output.noaccts,...
//SYSIN DD *
JOINKEYS FILE=F1,FIELDS=(24,8,A,32,8,A)
JOINKEYS FILE=F2,FIELDS=(24,8,A,32,8,A)
JOIN UNPAIRED,F1,ONLY
SORT FIELDS=COPY
/*
FREE TUTORIALS
Tutorials
Free tutorials from mainframegurukul
- JCL Tutorial
Covers all important JCL concepts. - Cobol Tutorial
This tutorials covers all Cobol Topics from STRING to COMP-3. - DB2 Tutorial
DB2 Tutorial focuses on DB2 COBOL Programming. - SORT Tutorial
This Tutorial covers all important aspects of DFSORT with examples - CICS Tutorial
This CICS tutorial covers CICS concepts and CICS Basics, CICS COBOL Programming.
Interview
Mainframe Interview questions
- Cobol Interview Questions
50+ Interview Questions - JCL Interview Questions
50+ Interview Questions - DB2 Interview Questions
100+ Interview Questions - CICS Interview Questions
70+ Interview Questions - VSAM Interview Questions
27 Interview Questions
Other References
Mainframe Tools and others
- XPEDITER Reference
Explains how we can debug a program - FILEAID Reference
Explains how to browse , edit and delete datasets - Change Man Reference
Quick Start tutorial on Changeman - Abend Reference
Important Abend codes explained - FaceBook Page
MainframeGurukul FaceBook Page - LinkedIn Page
MainframeGurkul Linkedin Page