unix join separator char

Viewed 38381

Sorry for the maybe trivial question.

I fought a bit with the unix join command, trying to get tabs instead of whitespaces as the default separators. -t is the argument, but these don't work (ubuntu 9.10 64 bit 2.6.31-14, GNU coreutils version 7.4)

join file1 file2 -t"\t"
join file1 file2 -t="\t"
join file1 file2 -t="\\t"
join file1 file2 -t $"\t"

Et cetera. Of course, I can always use some inelegant solution like

join file1 file2 > output
sed "s/ /\t/g" output

But I wanted to look smart :-) Moreover, if there's a -t argument, it must work.

6 Answers
Related