Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Any utility with which we can do this, DONT write COBOL pgm

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
ashish_tech

New User


Joined: 28 Dec 2005
Posts: 1

PostPosted: Thu Jan 15, 2009 12:24 pm    Post subject: Any utility with which we can do this, DONT write COBOL pgm
Reply with quote

I have two sequential files, FILE-1 and FILE-2.
FILE-1 contains 2 columns(A,B) and FILE-2 contains 3 columns
(C,D,E).I want an output file, FILE-3 which has all five
columns with duplicates eliminated from column A.

Let me know if need more details...
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 Jan 15, 2009 12:34 pm    Post subject:
Reply with quote

More details needed.......

Did you search before posting ? because this is a very common topic in both the JCL and DFSORT forums.

LRECL & RECFM for both files.

Do both files have the exact same number of records to perform a 1 to 1 merge, if not what happens in this case.

Do the duplicates get removed from column 1 before or after the two files are merged as this may affect the number of records in file 1
Back to top
View user's profile Send private message
Mukesh Pandey

Active User


Joined: 11 Nov 2008
Posts: 143
Location: India

PostPosted: Thu Jan 15, 2009 4:10 pm    Post subject:
Reply with quote

USE sort utility............ hope below explanation helps....
1. SORT FIELDS=COPY

It is for copy records to output file

2. INREC FIELDS=(7:2,5,20:10,3) (for formatting)

Here we have two formattings,

1. 7:2,5 - data at 2nd position of input file with length 5
copied to 7th position of output file

2. 20:10,3 - data at 10th position of input file with length 3
copied to 20th position of output file

........for eliminating duplicates, use ....
SUM FIELDS=NONE,XSUM
Back to top
View user's profile Send private message
Mukesh Pandey

Active User


Joined: 11 Nov 2008
Posts: 143
Location: India

PostPosted: Thu Jan 15, 2009 4:14 pm    Post subject:
Reply with quote

expat, let me know if this works out assuming, lrecl, recfm and the number of records are same in two files.
Back to top
View user's profile Send private message
Arun Raj

Moderator


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

PostPosted: Thu Jan 15, 2009 4:29 pm    Post subject:
Reply with quote

Mukesh,

Unless the OP responds to the questions asked here, we cannot offer suggestions as he might know what is his requirement and not any of us.
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts IEW2456E error when link-editing a C ... Senthilraj JCL & VSAM 0 Fri Oct 13, 2017 3:12 pm
No new posts How to write Rexx program to size and... sreejeshcs CLIST & REXX 14 Thu Oct 12, 2017 7:26 am
No new posts Table(Unicode(Graphic) table) loading... muralikrishnan_new DB2 0 Thu Oct 05, 2017 5:10 pm
No new posts Assembler Macro Copybook converted to... Ziquilix PL/I & Assembler 4 Tue Sep 26, 2017 3:07 am
This topic is locked: you cannot edit posts or make replies. Extract all "IF" Statements... Adarsh Damodaran CLIST & REXX 1 Wed Sep 06, 2017 9:28 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us