title: sending a mail using informatica workflow
body: <p>I have an informatica mapping-a simple one which has <code>Sq-&gt;t(x)-&gt;tgt</code></p>
  
  <p>Here I am populating the target (which is a flat file) only if a certain condition is satisfied, which is included  in the transformations.</p>
  
  <p>Now my requirement is that if the target (a txt file) is populated even with even one record it should send out an email to two people.</p>
  
  <p>I am using the <code>mailx</code> Unix command but I am not sure how to check whether there are any records in the target file using Unix script. This is what I have tried:</p>
  
  <pre><code>if [ "/data/informatica/Services/myfolder/TgtFiles/filename.csv" = "1" ]//here i am trying to check if there are any records in the target
  then
      mailx -s "Target is populated" "reciepent1@abc.com reciepent2@abc.com "&lt;&lt;ed
      Validation completed
      ed
  else
      exit
      eod
  fi
  </code></pre>