You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Sebb (JIRA)" <ji...@apache.org> on 2019/06/16 20:26:00 UTC
[jira] [Resolved] (CSV-135) Char escape doesn't work properly with
quoting
[ https://issues.apache.org/jira/browse/CSV-135?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Sebb resolved CSV-135.
----------------------
Resolution: Fixed
7754cd4 CSV-135 - Char escape doesn't work properly with quoting
> Char escape doesn't work properly with quoting
> ----------------------------------------------
>
> Key: CSV-135
> URL: https://issues.apache.org/jira/browse/CSV-135
> Project: Commons CSV
> Issue Type: Bug
> Components: Printer
> Affects Versions: 1.0
> Reporter: Mateusz Zakarczemny
> Priority: Major
> Fix For: Patch Needed
>
>
> Following code:
> {code}
> CSVFormat format = CSVFormat.DEFAULT
> .withRecordSeparator('\n')
> .withQuote('"')
> .withEscape('\\');
> CSVPrinter printer = new CSVPrinter(System.out, format);
> List<String> l = new LinkedList<String>();
> l.add("\"");
> l.add("\n");
> l.add("\\");
> printer.printRecord(l);
> {code}
> produces
> {code}
> """","
> ","\"
> {code}
> instead of
> {code}
> "\"","\n","\\"
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)