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

Comparing 2 files using ICETOOL


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
creativity

New User


Joined: 10 Feb 2006
Posts: 3
Location: India

PostPosted: Fri May 18, 2007 4:29 pm
Reply with quote

I have two files FILEA and FILEB. FILEA has LRECL = 170 while FILEB has LRECL = 30. Position 1-16 of both files refer to ID number. I need to created three output files in the following way.

OUTFILE1 should contain matching record of FILEA and FILEB,
OUTFILE2 should contain non matching record that appear only in FILEA
OUTFILE3 should contain non matching record that appear only in FILEB

e.g.:

FILEA :

11111111111111111111NAME1.........................
22222222222222222222NAME1.........................
33333333333333333333NAME1.........................
44444444444444444444NAME1.........................
55555555555555555555NAME1.........................

FILEB :

22222222222222222222
55555555555555555555
66666666666666666666
77777777777777777777

The output should be:

OUTFILE1
-----------
22222222222222222222
55555555555555555555

OUTFILE2
-----------
11111111111111111111
33333333333333333333
44444444444444444444

OUTFILE3
-----------
66666666666666666666
77777777777777777777


Please help me out in this. Its Urgent.
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Fri May 18, 2007 4:40 pm
Reply with quote

And the topic which was top of the forum before your post deals with this.

http://ibmmainframes.com/viewtopic.php?t=21030
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Sun May 27, 2007 12:15 am
Reply with quote

You can use the technique shown in the "Create files with matching and non-matching records" Smart DFSORT Trick at:

www.ibm.com/servers/storage/support/software/sort/mvs/tricks/

You'll need to pad the 30 byte records to 170 bytes.
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 -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 3
No new posts Compare 2 files(F1 & F2) and writ... JCL & VSAM 8
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 Shift left VB record without x00 endi... DFSORT/ICETOOL 11
Search our Forums:

Back to Top