zeroshade opened a new pull request, #1508:
URL: https://github.com/apache/arrow-go/pull/1508
### Rationale for this change
Inside a CSV list value, a null item is written as the writer's null string,
so a non-null item equal to that string reads back as null. For example, with
`WithNullWriter("null")` and `WithNullReader(true, "null")`, `["null"]` and
`[null]` both write as `{null}`. The same happens for empty strings when the
null string is empty.
### What changes are included in this PR?
- The writer quotes non-null list items equal to the null string, so
`["null", null]` writes as `{"null",null}`.
- The reader never treats a quoted list item as null.
- Unquoted items keep their current behavior, so existing files read the
same.
This builds on #1505, which is the first commit here. Only the last commit
is new.
### Are these changes tested?
Yes.
### Are there any user-facing changes?
Yes. CSV output quotes list items that equal the null string, and readers
treat quoted list items as non-null. With an empty null string, a list whose
only item is null still reads back as an empty list; the `WithNullWriter` docs
note this.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]