Ravi Sir's Cards › AWS
Pass a shell variable to awk?
This interview card answers: Pass a shell variable to awk? $x inside quotes is not shell. Use -v to pass it. Threshold check.
Read card text
What this card says
What it is
$x inside quotes is not shell.
Why it matters
Use -v to pass it.
How / example
Threshold check.
awk -v lim=80 '$2>lim' usage.txt