IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Comparing 2 sequential files using alphanumeric key


IBM Mainframe Forums -> FAQ & Basics
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Priya Karthik

New User


Joined: 12 Aug 2021
Posts: 2
Location: India

PostPosted: Thu Aug 12, 2021 1:02 pm
Reply with quote

I have a requirement where 2 sequential files needs to be compared using a alphanumeric key and matched records need to be written to a output file. I have seen logics where numeric keys are compared. is it possible to compare the alphanumeric in the same way as below?

Match-para:
-------------
if key1=key2
write output

if key1<key2
read inputfile1
perform match-para

if key2>key1
read inputfile2
perform match-para

Kindly help me whether i can follow the same condition checking for alphanumeric as well?
Back to top
View user's profile Send private message
prino

Senior Member


Joined: 07 Feb 2009
Posts: 1325
Location: Vilnius, Lithuania

PostPosted: Thu Aug 12, 2021 3:52 pm
Reply with quote

You're an expert? Posting on a forum for experts?

Why the flucking hell couldn't an expert like you test it yourself?

'nuff said!
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3109
Location: NYC,USA

PostPosted: Thu Aug 12, 2021 3:53 pm
Reply with quote

Welcome!
Moved the topic to Student forum.

I would suggest you give a try and see what happens. Besides you can do any of such operations using DFSORT much quicker than COBOL programming. Think about that too.
Back to top
View user's profile Send private message
Priya Karthik

New User


Joined: 12 Aug 2021
Posts: 2
Location: India

PostPosted: Fri Aug 13, 2021 3:53 pm
Reply with quote

I will do the testing. My requirement is not to use DFSORT and need to compare using COBOL programming.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3109
Location: NYC,USA

PostPosted: Fri Aug 13, 2021 4:50 pm
Reply with quote

So then definitely you must code and try.
Back to top
View user's profile Send private message
View previous topic : : View next topic  
Post new topic   Reply to topic All times are GMT + 6 Hours
Forum Index -> FAQ & Basics

 


Similar Topics
Topic Forum Replies
No new posts INPFIL FILES, FNAMES examples SYNCSORT 7
No new posts FileAid move data from two files to o... Compuware & Other Tools 5
No new posts JCL to merge two files side by side DFSORT/ICETOOL 3
No new posts Create a specific record/file based o... SYNCSORT 8
No new posts 3 files concatenated to 1 DFSORT/ICETOOL 2
Search our Forums:


Back to Top