title: Apache CSV Quote Character Does Not Work For Multiple Columns
body: <p>I read a very simple CSV file like this:</p>
  <pre class="lang-java prettyprint-override"><code>String csv = &quot;'ID', 'fruit'\n'1', 'apple'\n'2', 'banana'\n'3', 'cherry'&quot;;
  
  try (InputStream resourceInputStream = new ByteArrayInputStream(csv.getBytes());
      InputStreamReader inputStreamReader = new InputStreamReader(resourceInputStream);) {
  
    CSVFormat format = CSVFormat.DEFAULT.withDelimiter(',').withHeader()
            .withSkipHeaderRecord(false).withRecordSeparator(&quot;\n&quot;).withTrim().withQuote('\'');
    CSVParser parser = format.parse(inputStreamReader);
    Iterator&lt;CSVRecord&gt; iterator = parser.iterator();
  
    while (iterator.hasNext()) {
      CSVRecord next = iterator.next();
      System.out.println(next.toMap());
    }
  }
  </code></pre>
  <p>This prints the following to the console:</p>
  <pre><code>{ID=1, 'fruit'='apple'}
  {ID=2, 'fruit'='banana'}
  {ID=3, 'fruit'='cherry'}
  </code></pre>
  <p>While I of course expect:</p>
  <pre><code>{ID=1, fruit=apple}
  {ID=2, fruit=banana}
  {ID=3, fruit=cherry}
  </code></pre>
  <p>And it's not purely cosmetic either, if there is a separator inside the quotes it's used as if the quotes were not present. (So using &quot;che,rry&quot; will put &quot;rry&quot; in the third column.)</p>
  <p>It does not work with &quot; instead of ' either. It does not work with the default quote (which should be &quot;, too). It does not work with <code>withQuoteMode()</code>. It does not work for the previous Apache CSV version (the current is 1.8, I tested 1.7 and 1.6).</p>
  <p>Does anyone have any idea what I need to do to make quotes work in the second and following columns?</p>
  <p><strong>Nevermind:</strong> It's working with <code>withIgnoreSurroundingSpaces()</code></p>