awk

awk

awk ‘NR==FNR{a[$1]}NR!=FNR{if ($1 in a) print $0}’ id.txt expre.txt > outfile.txt

 

awk ‘NR==FNR{a [$1]}NR>FNR{if ($1 in a) print $0}’ id.txt expre.txt > outfile.txt

awk ‘ARGIND==1{a [$1]}ARGIND==2{if ($1 in a )print $0 }’ id.txt expre.txt > outfile.txt
awk ‘FILENAME=ARGV[1]{a[$1]}FINENAME=ARGV[2]{if ($1 in a)print $0}’ id.txt expre.txt > outfile.txt
awk ‘NR=FNR{a[$2]}NR!=FNR{if ($1 in a) print a[$1],b[$0]}’ infile1 inflie2 > outfile.txt
awk ‘NR=FNR{a[$1]}NR>FNR{if($1 in a) print$0}’ infile1.txt infile2.txt > outfile.txt

cat id.txt | awk ‘//{print}’ >> id.1.txt

sort infile | uniq > outfile
awk ‘!a[$0]++’ infle > outfie
awk -F % ‘NR==7,NR==15 {printf $1 $3 $7}’

不要问我为什么不排版,本人注重内容,别整的太花哨了,哈哈,随意awk就好!

欢迎关注公众微信号

2019_03_26_1027386957

如若有问题,或侵犯您的版权,请您及时联系我smyang2018@gmail.com,谢谢您!

smyang2018

跳至工具栏