GitHub user HyukjinKwon opened a pull request:
https://github.com/apache/spark/pull/20877
[SPARK-23765][SQL] Supports line separator for json datasource
## What changes were proposed in this pull request?
This PR proposes to add lineSep option for a configurable line separator in
text datasource.
It supports this option by using `LineRecordReader`'s functionality with
passing it to the constructor.
The approach is similar with https://github.com/apache/spark/pull/20727;
however, one main difference is, it uses text datasource's `lineSep` option to
parse line by line in JSON's schema inference.
## How was this patch tested?
Manually tested and unit tests were added.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/HyukjinKwon/spark linesep-json
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/spark/pull/20877.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #20877
----
commit c674f4a5b4d581814a98a2eb23dcffdce9fea661
Author: hyukjinkwon <gurwls223@...>
Date: 2018-03-03T11:21:10Z
Supports line separator for json datasource
----
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]