The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM



View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 05-07-2008
gamma_user gamma_user is offline
Registered User
 

Join Date: May 2008
Posts: 7
join not working

I was trying to merge the following two example files using their first field:

join -1 1 -2 1 file1 file 2

but nothing is produced. The expected result should be:

rs1005152 7 q21.3 3

It appears that the length of the first field in file1 is causing the problem. Any suggesting on how to use join to produce the desired result? I know there are other ways to get the result but I have to use the join because the real files are huge.

Thanks in advance.


file1:
rs10051507 5 q21.3
rs10051514 5 p15.32
rs10051527 5 q21.2
rs1005152 7 q21.3
rs10051540 5 q21.3
rs10051548 5 q21.1
rs1005155 X q27.3
rs10051594 5 q34

file2:
rs1003456 3
rs1005152 3
Reply With Quote
Forum Sponsor