The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




Thread: A join problem?
View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #3 (permalink)  
Old 02-06-2007
aigles's Avatar
aigles aigles is offline Forum Advisor  
Registered User
  
 

Join Date: Apr 2004
Location: Bordeaux, France
Posts: 1,433
A possible way :
Modify your input files :

Code:
username firstname secondname group,score

and try something like that :

Code:
join -t, -a 1 -a 2 -o 0 1.2 2.2  -e "0" ass1.$$ ass2.$$ |
join -t, -a 1 -a 2 -o 0 1.2 1.3 2.2  -e "0" -   ass3.$$ |
join -t, -a 1 -a 2 -o 0 1.2 1.3 1.4 2.2  -e "0" - ass4.$$ > sorted.$$


Jean-Pierre.