title: pipe inside (awk) System command in cpp
body: <p>I have the awk command wch I want to wrap in system(). </p>
  
  <pre><code>std::string cmd = "awk -F\|  '{ var1=$2; var2=$5; print var1, var2 }' 1.txt";
  system(cmd.c_str());
  </code></pre>
  
  <p>Getting the error as,</p>
  
  <blockquote>
    <p>error: unknown escape sequence '\|'</p>
  </blockquote>
  
  <p>I have tried giving the quotes in different way. But, nothing helps.</p>