1

match two key columns in two files and print output (awk)

view story
linux-howto

http://www.unix.com – I have two files… file1 and file2. Where columns 1 and 2 of file1 match columns 1 and 2 of file2 I want to create a new file that is all file1 + columns 3 and 4 of file2 :b: Many thanks if you know how to do this.... :b: file1 31-101 106 0 92 31-101 106 29 92 31-101 106 85 12 31-101 106 66 11 31-101 106 71 33 31-101 146 0 14 31-101 146 45 14 31-101 146 94 14 31-101 146 86 15 31-101 146 93 15 31-101 146 (HowTos)