I've two file with FB record formate
File A - Record length - 9
File B - Records Lenght - 300
I need to comparea a number from File A in position ( 1,9) to a number
in FIle B in position (2,9).
My Requirement
1) I want two output files OUT1 with matched records from File B
2) Output file OUT2 with unmatched records from File A.
In the output file OUT1 I want the whole record for the matched records to come inthe output.In the OUT2 just the numbers shouold be enough.
Request you to give me the SORT and ICETOOL JCL.
Kindly let me know for more information.
SORT JCL to seperate Matched and unmatched records
Moderators: Frank Yaeger, Moderator Group
-
- Moderator
- Posts: 1625
- Joined: Sat Aug 09, 2008 9:02 am
- Location: Mumbai, India
Re: SORT JCL to seperate Matched and unmatched records
You mihgt like to review your post again for these lines:
For File A - number is of length 9 while for File B it's of just 8 - two numbers of differnet number of digits can never be same unless you are keeping the possibilty of having leading-zero in some numbers; but even if so - you've not stated that.vikasbs wrote:I need to comparea a number from File A in position ( 1,9) to a number in FIle B in position (2,9).
Regards,
Anuj
Anuj
SORT JCL to seperate Matched and unmatched records
Hi Anuj,
The number in File A starts from collumn 1
- - - - + - - - - 1
11 11 1 1 11 1
The same number in File A in File B start from collumn 2
- - - - + - - - - 1 -
21 11 1 1 1 11 1
Hope I am clear.
Regards
Vikas
The number in File A starts from collumn 1
- - - - + - - - - 1
11 11 1 1 11 1
The same number in File A in File B start from collumn 2
- - - - + - - - - 1 -
21 11 1 1 1 11 1
Hope I am clear.
Regards
Vikas
-
- Moderator
- Posts: 1625
- Joined: Sat Aug 09, 2008 9:02 am
- Location: Mumbai, India
So yo actually menat (2,10) - length of key is 9.
Please have a look at "Create files with matching and non-matching records at location: http://www.ibm.com/support/docview.wss? ... g3T7000094. You might need to make some adjustments, but it should give you a start.
Good Luck
Please have a look at "Create files with matching and non-matching records at location: http://www.ibm.com/support/docview.wss? ... g3T7000094. You might need to make some adjustments, but it should give you a start.
Good Luck
Regards,
Anuj
Anuj
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