-
csvtk join
: support the 2nd or later files with entries with same ID: e.g.:$ cat 1.csv name,attr foo,cool bar,handsome bob,beutiful $ cat 2.csv name,major bar,bioinformatics bob,microbiology bob,computer science $ cat 3.csv id,name,hobby 1,bar,baseball 2,bob,basketball 3,foo,football 4,wei,programming $ csvtk join 1.csv 2.csv | csvtk pretty name attr major bar handsome bioinformatics bob beutiful microbiology bob beutiful computer science $ csvtk join 1.csv 2.csv 3.csv -f name -k | csvtk pretty name attr major id hobby foo cool 3 football bar handsome bioinformatics 1 baseball bob beutiful microbiology 2 basketball bob beutiful computer science 2 basketball $ csvtk join 3.csv 1.csv 2.csv -f name -k | csvtk pretty id name hobby attr major 1 bar baseball handsome bioinformatics 2 bob basketball beutiful computer science 2 bob basketball beutiful computer science 3 foo football cool 4 wei programming