Opened 5 years ago
Last modified 5 years ago
#13253 new Feature Requests
RFC 4180 CSV separator
Reported by: | Owned by: | jsiek | |
---|---|---|---|
Milestone: | To Be Determined | Component: | tokenizer |
Version: | Boost 1.63.0 | Severity: | Problem |
Keywords: | Cc: |
Description
It would be useful to have a RFC 4180 CSV separator alternative to escaped_list_separator
. The RFC 4180 CSV format is more compatible with popular spreadsheet software. It really is a different format:
- Putting quotes around a field allows commas only if the initial quote is at the beginning of the field.
- Quotes can be embedded in a quoted field if they are repeated. For example:
field 1,"embedded "" in field 2",field 3
- Newlines can be embedded in a quoted field.
- There is no escape character (except for the special case of a repeated quote).
It is easy to write a tokenizer function that parses this format, except for the embedded newlines. I have some working code that could be cleaned up and submitted.
Note:
See TracTickets
for help on using tickets.
Please create a PR so it can be discussed.