Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Compare two sequential files omitting some fields

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
sudhirk63

New User


Joined: 08 Oct 2006
Posts: 19
Location: Bangalore

PostPosted: Sun Jan 07, 2007 7:43 pm    Post subject: Compare two sequential files omitting some fields
Reply with quote

Hello All,

There are lots of posts on file comparision , however I could not find any to satisfy my needs, hence this post.

I have to compare two sequential files omitting some fields from the comparison ( the fields to be omitted may not be in sequence) and if difference is found report the key( which is first four characters of File A and the starting and if possible the ending position of the record.

For example :
The input file is FB and LRECL is 80. The fields to be not considered for comparison lie between 6 to 7 and 11 to 14.
A sample FileA record is as :
0001TOBEORNOTTOBE

Sample FileB record is as :
0001TOBEORNOTTBEE

After the comparison the output report should look like :

0001 - 15,16

Thanks.

Regards.

Sudhir
Back to top
View user's profile Send private message

dick scherrer

Site Director


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

PostPosted: Mon Jan 15, 2007 7:13 am    Post subject:
Reply with quote

Hello,

You'll have complete control and can format the output any way you'd like if you create some COBOL code to match the files and do what you want.

There has been recent discussion on matching files.
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Mon Jan 15, 2007 9:51 am    Post subject:
Reply with quote

If you have SUPERC, you can use NEXCLUDE and OEXCLUDE statements to ignore specific positions. You can read more about it in the fine manual.

O.
Back to top
View user's profile Send private message
dick scherrer

Site Director


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

PostPosted: Mon Jan 15, 2007 10:24 am    Post subject:
Reply with quote

Hello,

If i understood what is needed, it is a report of the starting and ending position of "the mismatched data" after matching the records on the "keys".

I don't believe the mismatch would always be in the same positions. I'm also not sure what should happen if there is more than one set of characters that don't match. From the small amount of sample data it is difficult to guess.

Hence, the suggestion to write code and make the output be whatever is required.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SYNCSORT SEQNUM and FI fields. nartcr SYNCSORT 5 Sat Jan 21, 2017 4:02 am
No new posts Storing huge volume of data, compare ... Pradeep K M All Other Mainframe Topics 3 Mon Jan 16, 2017 5:08 pm
No new posts Syncsort Help to group fields sudhakarraju SYNCSORT 6 Thu Dec 29, 2016 1:38 am
No new posts High CPU consumption Job using IAM fi... aswinir JCL & VSAM 15 Thu Dec 01, 2016 8:28 pm
No new posts Match or compare two files in VB Format anatol DFSORT/ICETOOL 14 Thu Nov 03, 2016 7:41 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us