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

joining on record


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

New User


Joined: 17 Apr 2009
Posts: 70
Location: India

PostPosted: Sun Dec 20, 2009 8:53 pm
Reply with quote

Hi All

I have a requirement like this, Can you please help

File 1 FB 80
Code:
1234 10000   1
1234 20000   4
1235 25000   10
1235 30000   10
1236 15000   5
1237 15000   10
1285 (spaces)20


File 2 FB 80
Code:
1234 10000   6
1235 25000   10
1235 35000   10
1236 15000   5


Keys here are first four bytes(1 to 4) and 18bytes (6 to 23), and need a out put some thing like this

Code:
1234 10000   1    6   
1234 20000   4    0
1235 25000   10  10
1235 30000   10  10
1236 15000   5    5
1237 15000   10   0
1285 (spaces)20   0


which means file is having a record 1234 10000 where its count in this file is 1 and file2 having a record 1234 10000 where its count is 6 so i need oput 1234 10000 1 6 (1 is from file1 and 6 is from file2 for same record)

there wont be dublicates and both the files will be in sorted order
There could be record which is there in file1 but not in file 2
Back to top
View user's profile Send private message
Lijo

New User


Joined: 24 Aug 2008
Posts: 41
Location: Cochin

PostPosted: Mon Dec 21, 2009 5:11 pm
Reply with quote

I tried understanding your output data. But this one didn't make sense to me. Is this correct?

Quote:
1235 30000 10 10


should this be 1235 30000 10 0???

Also,
Quote:
Keys here are first four bytes(1 to 4) and 18bytes (6 to 23),

18bytes for secondary Keys, But in your example I couldn't recognize this 18 bytes. Are you looking for a match on 6 to 6 bytes?
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1193
Location: Dublin, Ireland

PostPosted: Mon Dec 21, 2009 5:46 pm
Reply with quote

Also, do you mean to drop the 3rd record from File2 - 1235 35000 10 ?

Garry.
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 How to split large record length file... DFSORT/ICETOOL 10
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
No new posts To find whether record count are true... DFSORT/ICETOOL 6
No new posts Validating record count of a file is ... DFSORT/ICETOOL 13
Search our Forums:

Back to Top