简体   繁体   English

linux AWK命令与操作符

[英]linux AWK command to with operarion

i get below result on Linux awk command, ,i want to grep all with greater than this filed [360] . 我在Linux awk命令上得到低于结果的结果,我想对所有大于此字段的grep进行grep [360]。 the filed name is $13 归档的名称为$ 13

[4]
[440]
[360]
[3]
[434]
[3]
[439]
[590]

the result should be : 结果应该是:

[440]
[434]
[439]
[590]

with awk: 与awk:

awk '{a=$0;gsub("[\\[\\]]","",$13);if(int($13)>360) {print a;}}' filename

it will print all lines, that action processed with greater than 360 mills. 它将打印所有行,并以超过360毫米的速度处理该动作。

awk  '!/\[3..\]|\[.\]/' file

[440]
[434]
[439]
[590]

Not to print three hundred... or one unit. 不打印三百...或一单位。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM