View previous topic :: View next topic
|
Author |
Message |
rally
New User
Joined: 28 Jul 2005 Posts: 37
|
|
|
|
I have 2 files with below info
File1
111aaa
111bbb
111ccc
222ddd
333eee
444fff
444ggg
444hhh
File2
111
333
File 2 contain some records with key equal part of File1.
we want to have below output:
Output Fil1 - contain those records with key in File2;
111aaa
111bbb
111ccc
333eee
Output File 2 - contain those records with key not in in File2;
222ddd
444fff
444ggg
444hhh
Can we use SORT/ICETOOL complete above logic? Thanks. |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
Yes, of course. It is a simple JOINKEYS with JOIN UNMATCHED,F1, a REFORMAT statement for the entire F1 and the match-marker, ?, and two OUTFILs which select on the match-marker and BUILD to get only the original data.
Lots of examples here. |
|
Back to top |
|
|
rally
New User
Joined: 28 Jul 2005 Posts: 37
|
|
|
|
Woodger,
Can you give me sample for this or some other OLD sample post/URL? Thanks |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
You joined 10 years ago. Click on the forum name, put JOINKEYS in the search-box and you should see over 400 examples. |
|
Back to top |
|
|
rally
New User
Joined: 28 Jul 2005 Posts: 37
|
|
|
|
@Woodger, I have solved issue now. Thanks. |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2455 Location: Hampshire, UK
|
|
|
|
Quote: |
You joined 10 years ago |
so you should also know how to use the code tags. |
|
Back to top |
|
|
|