Skip to content

Commit 55257c2

Browse files
Bikramjeet Vigfacebook-github-bot
authored andcommitted
Back out "fix(json): Ensure input is parsed as json for json extract functions" (facebookincubator#12514)
Summary: Pull Request resolved: facebookincubator#12514 Temporarily backing out this change as it is failing some internal unit tests. Reviewed By: kgpai Differential Revision: D70498020 fbshipit-source-id: 1137958fb0c87e4e53bc78bb12ea16c75124aeff
1 parent 152e624 commit 55257c2

File tree

8 files changed

+273
-538
lines changed

8 files changed

+273
-538
lines changed

velox/docs/functions/presto/json.rst

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -156,8 +156,6 @@ JSON Functions
156156
SELECT json_extract(json, '$.store.book');
157157

158158
Current implementation supports limited subset of JSONPath syntax.
159-
If ``json`` is a varchar then it is expected to conform to `RFC 7159`_ and will be converted to its canonical
160-
format before extraction.
161159

162160
.. _JSONPath: http://goessner.net/articles/JsonPath/
163161

@@ -171,10 +169,6 @@ JSON Functions
171169
SELECT json_extract_scalar('[1, 2, 3]', '$[2]');
172170
SELECT json_extract_scalar(json, '$.store.book[0].author');
173171

174-
Current implementation supports limited subset of JSONPath syntax.
175-
If ``json`` is a varchar then it is expected to conform to `RFC 7159`_ and will be converted to its canonical
176-
format before extraction.
177-
178172
.. _JSONPath: http://goessner.net/articles/JsonPath/
179173

180174
.. function:: json_format(json) -> varchar
@@ -189,9 +183,8 @@ JSON Functions
189183

190184
.. function:: json_parse(varchar) -> json
191185

192-
Expects a JSON text conforming to `RFC 7159`_, and returns the JSON value (in its canonical form) deserialized
193-
from the JSON text. The JSON value can be a JSON object, a JSON array, a JSON string, a JSON number, ``true``,
194-
``false`` or ``null``::
186+
expects a JSON text conforming to `RFC 7159`_, and returns the JSON value deserialized from the JSON text.
187+
The JSON value can be a JSON object, a JSON array, a JSON string, a JSON number, ``true``, ``false`` or ``null``::
195188

196189
SELECT json_parse('[1, 2, 3]'); -- JSON '[1,2,3]'
197190
SELECT json_parse('"abc"'); -- JSON '"abc"'

0 commit comments

Comments
 (0)