title: using grep as if condition inside awk
body: <p>I can use <code>grep -Fxq search-string text-file</code> outside of my awk, and it works they way I'd expect (found here <a href="https://stackoverflow.com/questions/4749330/how-to-test-if-string-exists-in-file-with-bash-shell">How to test if string exists in file with Bash shell?</a>). But, when I try to use that same grep command as an if statement inside awk, it seems to do nothing. Here's the basic usage I'm trying:</p>
  
  <pre><code>cat /var/log/somelogfile | awk '{ if (grep -Fxq $1 textfile) print "useful command $1" }'
  </code></pre>