I have a tsv file with data from some event participants. Here is a small snippet from it:
...
sub-09 37 F 19780726 20160328 20160329
sub-10 38 F 19780208 20160406 20160407
sub-11 39 M 19770511 20160704 20160705
...
sub-42 37 F 19780726 20160328 20160329
...
Note that sub-09 and sub-42 are duplicates.
In BASH, how can I find duplicate lines but ignoring the first (or in general any other) column? I've seen similar threads, e.g., this one, but I couldn't find an answer that fits. Ideally I would get both occurrences of all duplicates, as in:
Expected output:
sub-09 37 F 19780726 20160328 20160329
sub-42 37 F 19780726 20160328 20160329