title: Awk print matched column if exists else print not found
body: <p>My text file looks like below </p>
  
  <pre><code>date="2017-10-10" ip=192.168.1.1:22 inbound=100 outbound=100
  date="2017-10-10" ip=192.168.1.1:22 inbound=100
  date="2017-10-10" ip=192.168.1.1:22  outbound=100
  </code></pre>
  
  <p>I am using the below awk code to print the matched string and extract whatever is after the "=". </p>
  
  <pre><code>awk '{for(i=1;i&lt;=NF;i++)if($i~/inbound=/)print $(i)}'  | cut -d : -f1 | cut -d = -f2
  </code></pre>
  
  <p>For example I would search for "inbound=" and extract the "100". 
  But the tricky part is "inbound" won't there in all the lines of the text
  Now I would like to print "0" if a line doesn't have the word "inbound".</p>
  
  <p><strong>Expected output</strong></p>
  
  <pre><code>100
  100
  0 Not Found
  </code></pre>