title: Removing spaces from columns of a CSV file in bash
body: <p>I have a CSV file in which every column contains unnecessary spaces(or tabs) after the actual value. I want to create a new CSV file removing all the spaces using bash. </p>
  
  <p>For example</p>
  
  <p>One line in input CSV file</p>
  
  <pre><code>abc def pqr             ;valueXYZ              ;value PQR              ;value4
  </code></pre>
  
  <p>same line in output csv file should be</p>
  
  <pre><code>abc def pqr;valueXYZ;value PQR;value4
  </code></pre>
  
  <p>I tried using awk to trim each column but it didnt work. Can anyone please help me on this ?</p>
  
  <p>Thanks in advance :)</p>
  
  <p>I edited my test case, since the values here can contain spaces.</p>