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

File comparision using Syncsort Joinkeys


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
cvijay784
Warnings : 1

New User


Joined: 18 Jun 2008
Posts: 54
Location: Colombo

PostPosted: Thu Jun 11, 2009 12:11 pm
Reply with quote

Hi,

My requirement is compare two files having same LRECL(1850) based on the key value using Syncsort. ( but in the two files the key positions are different)

In my final output, i want only the matched records from file1.

I tried using the below Joinkeys fuction but am getting the matched records from both the files.

JOINKEYS FILE=F1,FIELDS=(1,22,A,1166,1,A,1827,3,A)
JOINKEYS FILE=F2,FIELDS=(1,22,A,23,1,A,24,3,A)
REFORMAT FIELDS=(F1:1,1850)
SORT FIELDS=COPY

Could anybody tell me whether i need to include any condition to report only the matched records from file1.

Thanks in advance!!!
Back to top
View user's profile Send private message
Escapa

Senior Member


Joined: 16 Feb 2007
Posts: 1399
Location: IL, USA

PostPosted: Thu Jun 11, 2009 12:32 pm
Reply with quote

cvijay, Post topic in relevant forum to get answer faster...

Why it is in CICS forum?
Back to top
View user's profile Send private message
cvijay784
Warnings : 1

New User


Joined: 18 Jun 2008
Posts: 54
Location: Colombo

PostPosted: Thu Jun 11, 2009 12:57 pm
Reply with quote

Yes..its an oversite error while submiitting the query..

Any reply pls to the query..
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2481
Location: @my desk

PostPosted: Thu Jun 11, 2009 2:31 pm
Reply with quote

Quote:
I tried using the below Joinkeys fuction but am getting the matched records from both the files.
Your requirement is not clear. If it is a "match", it's quite natural that you have the key in both the files and the control cards shown by you give ONLY the MATCHED records. And since you use REFORMAT FIELDS=(F1:1,1850), you should be getting File-1 records which has a match in File-2. Is n't that you're trying to achieve ?

If not, just show a few sample input records from your input and the output records you expect from it(only relevant fields).
Back to top
View user's profile Send private message
r2k1984

New User


Joined: 21 Jun 2005
Posts: 69
Location: chennai

PostPosted: Thu Jun 11, 2009 7:09 pm
Reply with quote

you can try file aid..

in which you can get the records you need only from which file..

that would be simple
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Thu Jun 11, 2009 7:12 pm
Reply with quote

r2k1984 wrote:
you can try file aid..
in which you can get the records you need only from which file..
that would be simple

But only if FileAid is installed at your site icon_rolleyes.gif
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2481
Location: @my desk

PostPosted: Thu Jun 11, 2009 8:11 pm
Reply with quote

r2k1984 wrote:
in which you can get the records you need only from which file..

that would be simple
With file-aid, can we do a two-file match and extract matching or non-matching records from either of the files, like SyncSort JOINKEYS?
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 FTP VB File from Mainframe retaining ... JCL & VSAM 1
No new posts Extract the file name from another fi... DFSORT/ICETOOL 6
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
Search our Forums:

Back to Top