Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有 nawk 命令来验证长度是否大于 12 则标记号有 $
我需要通过添加一个条件来使用相同的以下命令,即长度应大于 12 且小于 17
nawk ' length($7) > 12 {$7=substr($7,1,6)"$$$$$$$$} 1 ' FS=\| OFS=\|
(length($7)>12) && (length($7)<17)
应该这样做