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 VB file and FB file

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

New User


Joined: 07 Jun 2013
Posts: 11
Location: USA

PostPosted: Thu Feb 12, 2015 2:46 pm    Post subject: Compare VB file and FB file
Reply with quote

Hi,

i have file1 (VB) with the length 1003, and file2 (FB) with the lenght 13.
i wanted to compare file1 and file2 and write matched file1 record in output file (VB). Can anyone help me on this?

I am using below code...but getting error.
Code:
//SYSIN    DD *                   
  JOINKEYS FILE=F1,FIELDS=(45,13,A)
  JOINKEYS FILE=F2,FIELDS=(1,13,A)
  REFORMAT FIELDS=(F1:1,1003)     
  SORT FIELDS=COPY                 
/*


Code'd
Back to top
View user's profile Send private message

Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7315

PostPosted: Thu Feb 12, 2015 3:46 pm    Post subject: Reply to: Compare VB file and FB file
Reply with quote

What error? Paste the details please.

I'd go with:
Code:

 REFORMAT FIELDS=(F1:1,4,5)


The 1,4 is the RDW, 5 on its own means "from position five to the end of the current record". With your 1003, you'll have potential problems.
Back to top
View user's profile Send private message
Marso

REXX Moderator


Joined: 13 Mar 2006
Posts: 1235
Location: Israel

PostPosted: Thu Feb 12, 2015 3:50 pm    Post subject:
Reply with quote

Do we have to guess which error you got ?
icon_evil.gif
Back to top
View user's profile Send private message
murali.andaluri

New User


Joined: 07 Jun 2013
Posts: 11
Location: USA

PostPosted: Thu Feb 12, 2015 3:51 pm    Post subject: Reply to: Compare VB file and FB file
Reply with quote

Thank you very much Bill, it is working fine now.
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 editting the file by inserting zeros ... pramodrsingh DFSORT/ICETOOL 9 Mon Aug 21, 2017 5:58 pm
No new posts Match two files using multiple keys a... santoshks1987 SYNCSORT 11 Fri Aug 18, 2017 10:50 am
No new posts Multiple VSAM files single output fil... Mohan Kothakota DFSORT/ICETOOL 11 Wed Aug 09, 2017 7:57 pm
This topic is locked: you cannot edit posts or make replies. rexx code to create a ps file Bharath Vikraman CLIST & REXX 4 Mon Aug 07, 2017 10:30 am
No new posts Split file based on comparsion to 2 f... Div Grad DFSORT/ICETOOL 3 Thu Jul 27, 2017 9:16 pm


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