commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gary Gregory (JIRA)" <>
Subject [jira] [Resolved] (CSV-168) CsvFormat.nullString should not be escaped
Date Tue, 19 Jan 2016 02:39:39 GMT


Gary Gregory resolved CSV-168.
       Resolution: Fixed
         Assignee: Gary Gregory
    Fix Version/s: 1.3

In SVN trunk now. Please verify and close this issue.

You can also try a SNAPSHOT for the Apache SNAPSHOT repository here:

> CsvFormat.nullString should not be escaped
> ------------------------------------------
>                 Key: CSV-168
>                 URL:
>             Project: Commons CSV
>          Issue Type: Bug
>          Components: Parser
>    Affects Versions: 1.2
>            Reporter: cornel creanga
>            Assignee: Gary Gregory
>            Priority: Minor
>             Fix For: 1.3
>         Attachments: codec-168-gg.diff
> Hello,
> Use case: I'm generating MySQL dump files (text format) - for more details check this
> Issue: The value null is represented as "\N". Also by default the escape char is '\N'.
The CsvPrinter.printAndEscape method will convert this value into {noformat}"\\N"{noformat}
> I suggest to modify the CsvPrinter in order to not escape the nullString value  - it
should be written as it is. I can create a pull request if you want.
> I consider it a minor issue because it can be mitigated by making sure that the escape
character is not a part of the nullString - however in my case it means that the LOAD commands
should be modified accordingly.

This message was sent by Atlassian JIRA

View raw message