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
 

 

comparing two fields of the same record for a file

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

New User


Joined: 23 Aug 2006
Posts: 13

PostPosted: Thu Dec 17, 2009 9:04 pm    Post subject: comparing two fields of the same record for a file
Reply with quote

Hi,

I want to check if the two fields of a record is same or not. If it is same, I would like to write such records to an output file.
Can we do it using ICETOOL/SORT. Pls suggest.

Example..

Input file:


f1 f2 f3 f4
111 AAABBB 111 TTTTT
345 FFFHHH 546 GGGG
414 FFFSSS 414 NNNN

Output file where field f1 is equal to f3:

111 AAABBB 111 TTTTT
414 FFFSSS 414 NNNN
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Thu Dec 17, 2009 9:12 pm    Post subject:
Reply with quote

Code:
  SORT    FIELDS=COPY             
  INCLUDE COND=(pos,len,format,EQ,pos,len,format)
Back to top
View user's profile Send private message
sushidas
Warnings : 2

New User


Joined: 23 Aug 2006
Posts: 13

PostPosted: Thu Dec 17, 2009 9:18 pm    Post subject:
Reply with quote

thank you
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 Split file based on comparsion to 2 f... Div Grad DFSORT/ICETOOL 3 Thu Jul 27, 2017 9:16 pm
No new posts Read two inputs and write into output... murali.andaluri DFSORT/ICETOOL 6 Wed Jul 26, 2017 7:35 pm
No new posts Extra character appears in file when ... Balu5491 All Other Mainframe Topics 1 Wed Jul 26, 2017 2:39 pm
No new posts SSH - known_hosts file configuration vasanthz All Other Mainframe Topics 2 Wed Jul 26, 2017 2:10 am
This topic is locked: you cannot edit posts or make replies. Fetching data from BAI File arunsoods JCL & VSAM 1 Wed Jul 19, 2017 4:28 pm


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