**150**wrote:

Dear All,

I have a number of accessions deposited in (i) a text file and (ii) a tab-delimited file;

(i)

calc.388956

calc.254634

calc.333221

calc.333250

.

(ii)

calc.388956 ENSDARG00000001015|ENSDART00000001148|1791

calc.388956 ENSDARG00000001015|ENSDART00000001148|1791

calc.254634 ENSDARG00000000966|ENSDART00000001092|6325

calc.114655 ENSDARG00000006612|ENSDART00000002247|2167 (not found in accession list)

calc.333221 ENSDARG00000017121|ENSDART00000002309|3174

calc.333250 ENSDARG00000004697|ENSDART00000002554|1819

calc.329445 ENSDARG00000007812|ENSDART00000002247|2163

.

I am looking for a script for comparing these two files and find similar the accession numbers (i) in the tabular file (ii) and report the corresponding rows.

I used a script;

grep -wFf accession.txt tabular_file.txt > result.txt

but, I think it is not working.

Thank you for all your help !