I have a file with 2 columns, the first column have a read ID from fastq, the second column have a ncbi taxi ID, like this:
and I have an archive with the taxid list of a specific taxos, like this:
I want to extract the lines with the taxid present on archive 2, but, some of the taxids presents the same number present on read ID. So I tried extract only the correct lines with fgrep, but, fgrep can't specify a column (in the case the column 2).
Anyone can help me? Briefly I need extract the whole line detecting a pattern in column 2 using a file with patterns.