title: Windows Batch: replace substring in CSV file
body: <p>This is a popular subject on the Web but I can't find a simple way to do a find-and-replace inside a CSV file. My CSV file looks like this:</p>
  
  <pre><code>"0.219530613504834,43.7737904197643,PR RUE D'ARTOIS"
  "0.522235882011867,41.7681203998576,PR DE LA FOSSE AU ROI"
  "0.039404145384227,44.7565229712732,PR DES PETITS PRES"
  </code></pre>
  
  <p>I need to remove double quotes at the beginning and end of each line.</p>
  
  <p>I tried the following script:</p>
  
  <pre><code>setlocal enabledelayedexpansion
  
  for /f "tokens=*" %%a in (D:/data.csv) do (
      set temp=%%a
      set temp=%temp:^"=%
  )
  </code></pre>
  
  <p>My logic is to store each line in <code>%%a</code> and to replace the double quotes by nothing. </p>
  
  <p>I escape the double quote with ^.</p>
  
  <p>This script is doing nothing. Could you help?</p>