aboutsummaryrefslogtreecommitdiff
path: root/python/pyspark
diff options
context:
space:
mode:
authorFelix Cheung <felixcheung_m@hotmail.com>2017-03-02 01:02:38 -0800
committerFelix Cheung <felixcheung@apache.org>2017-03-02 01:02:38 -0800
commit8d6ef895ee492b8febbaac7ab2ef2c907b48fa4a (patch)
tree497d97fb9ca0c033baccc47eb5fddb4196fbf36a /python/pyspark
parentd2a879762a2b4f3c4d703cc183275af12b3c7de1 (diff)
downloadspark-8d6ef895ee492b8febbaac7ab2ef2c907b48fa4a.tar.gz
spark-8d6ef895ee492b8febbaac7ab2ef2c907b48fa4a.tar.bz2
spark-8d6ef895ee492b8febbaac7ab2ef2c907b48fa4a.zip
[SPARK-18352][DOCS] wholeFile JSON update doc and programming guide
## What changes were proposed in this pull request? Update doc for R, programming guide. Clarify default behavior for all languages. ## How was this patch tested? manually Author: Felix Cheung <felixcheung_m@hotmail.com> Closes #17128 from felixcheung/jsonwholefiledoc.
Diffstat (limited to 'python/pyspark')
-rw-r--r--python/pyspark/sql/readwriter.py4
-rw-r--r--python/pyspark/sql/streaming.py4
2 files changed, 4 insertions, 4 deletions
diff --git a/python/pyspark/sql/readwriter.py b/python/pyspark/sql/readwriter.py
index ec47618e73..45fb9b7591 100644
--- a/python/pyspark/sql/readwriter.py
+++ b/python/pyspark/sql/readwriter.py
@@ -163,8 +163,8 @@ class DataFrameReader(OptionUtils):
"""
Loads a JSON file and returns the results as a :class:`DataFrame`.
- Both JSON (one record per file) and `JSON Lines <http://jsonlines.org/>`_
- (newline-delimited JSON) are supported and can be selected with the `wholeFile` parameter.
+ `JSON Lines <http://jsonlines.org/>`_(newline-delimited JSON) is supported by default.
+ For JSON (one record per file), set the `wholeFile` parameter to ``true``.
If the ``schema`` parameter is not specified, this function goes
through the input once to determine the input schema.
diff --git a/python/pyspark/sql/streaming.py b/python/pyspark/sql/streaming.py
index 7587875cb9..625fb9ba38 100644
--- a/python/pyspark/sql/streaming.py
+++ b/python/pyspark/sql/streaming.py
@@ -433,8 +433,8 @@ class DataStreamReader(OptionUtils):
"""
Loads a JSON file stream and returns the results as a :class:`DataFrame`.
- Both JSON (one record per file) and `JSON Lines <http://jsonlines.org/>`_
- (newline-delimited JSON) are supported and can be selected with the `wholeFile` parameter.
+ `JSON Lines <http://jsonlines.org/>`_(newline-delimited JSON) is supported by default.
+ For JSON (one record per file), set the `wholeFile` parameter to ``true``.
If the ``schema`` parameter is not specified, this function goes
through the input once to determine the input schema.