Find content of one file from another file in UNIX

前端 未结 8 599
攒了一身酷
攒了一身酷 2020-12-01 07:39

I have 2 files. First file contains the list of row ID\'s of tuples of a table in the database. And second file contains SQL queries with these row ID\'s in \"where\" clause

8条回答
  •  庸人自扰
    2020-12-01 08:19

    Most of previous answers are correct but the only thing that worked for me was this command

    grep -oi -f a.txt b.txt
    

提交回复
热议问题