Thursday, April 23, 2009
Unix Join with tabs
This one had me scratching my head for a while yesterday. When you use the unix 'join' command with the default separators (whitespace) then you can join tab delimited files, but the output is space delimited.
I tried specifying the join character with -t "\t" or -t '\t' and even the despearate -t\t, but none of that works. Turns out you have to use an *actual* quoted tab character (which I found through a quick google search, the solution was here, thank you JJinuxLand).
You can insert a tab on the command line with the following key combo "ctrl-v <tab>
Job's a goodun.