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

Compare two files having different keys


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Minu Mary Raju

New User


Joined: 20 Nov 2007
Posts: 5
Location: Chennai

PostPosted: Fri Oct 10, 2008 11:52 am
Reply with quote

Hi,

I want to compare 2 input files and produce an output file, when there is a match between the key of file1 and file2. I want to write all records from file 1 to the output file, whenever a match is found. Here the Key position as well as the format of keys are different. And both files can contain duplicate records also.

Someone please respond to this as am in a critical situation to finish off this task.

Thanks in Advance
Minu.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Fri Oct 10, 2008 12:04 pm
Reply with quote

You have not provided nearly enough information for anyone to help you.

How are we supposed to know anything about the file layout without your giving us any information.

RECFM=
LRECL=
Key pos file 1 =
Key pos file 2 =
My sort product is ............
How are duplicates in both files to be handled ?

Also, there are numerous threads of the same topic in the JCL & DFSORT forums. Have you used the search button at the top of the page.

What have you tried for yourself and what are the errors you get.

Quote:
Someone please respond to this as am in a critical situation to finish off this task.

It is rather a bad move to rely on the answers of a forum given your parlerous state of having to complete this soon. Hence my request for the results of your own attempts.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Fri Oct 10, 2008 12:41 pm
Reply with quote

Hello,

Quote:
Here the Key position as well as the format of keys are different
If one of your keys is employee number and the other key is employee name, you have a problem. . .

As Expat mentioned, you have provided no details for someone to us to help you.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Write line by line from two files DFSORT/ICETOOL 7
No new posts Compare only first records of the fil... SYNCSORT 7
No new posts Merge two VSAM KSDS files into third ... JCL & VSAM 6
No new posts Joinkeys - 5 output files DFSORT/ICETOOL 7
No new posts How to append a PS file into multiple... JCL & VSAM 3
Search our Forums:

Back to Top