Skip to content

Add support for multiple Trino JSON functions#2382

Open
davyboyhayes wants to merge 1 commit intoJSQLParser:masterfrom
davyboyhayes:fix/2368
Open

Add support for multiple Trino JSON functions#2382
davyboyhayes wants to merge 1 commit intoJSQLParser:masterfrom
davyboyhayes:fix/2368

Conversation

@davyboyhayes
Copy link
Contributor

Adding support for clauses in JSON Functions. Fixes #2368

Adds support for the extra clauses found in Trino's JSON functions https://trino.io/docs/current/functions/json.html#json-exists, and includes test cases for these extra functions directly taken from the documentations.

Before:
Result "net.sf.jsqlparser.benchmark.JSQLParserBenchmark.parseSQLStatements":
34.858 ±(99.9%) 1.724 ms/op [Average]
(min, avg, max) = (32.578, 34.858, 38.383), stdev = 2.302
CI (99.9%): [33.133, 36.582] (assumes normal distribution)

After:
Result "net.sf.jsqlparser.benchmark.JSQLParserBenchmark.parseSQLStatements":
36.154 ±(99.9%) 1.701 ms/op [Average]
(min, avg, max) = (33.100, 36.154, 38.353), stdev = 2.271
CI (99.9%): [34.453, 37.855] (assumes normal distribution)

Adding support for clauses in JSON Functions. Fixes JSQLParser#2368

Adds support for the extra clauses found in Trino's JSON functions https://trino.io/docs/current/functions/json.html#json-exists, and includes test cases for these extra functions directly taken from the documentations.

Before:
Result "net.sf.jsqlparser.benchmark.JSQLParserBenchmark.parseSQLStatements":
  34.858 ±(99.9%) 1.724 ms/op [Average]
  (min, avg, max) = (32.578, 34.858, 38.383), stdev = 2.302
  CI (99.9%): [33.133, 36.582] (assumes normal distribution)

After:
Result "net.sf.jsqlparser.benchmark.JSQLParserBenchmark.parseSQLStatements":
  36.154 ±(99.9%) 1.701 ms/op [Average]
  (min, avg, max) = (33.100, 36.154, 38.353), stdev = 2.271
  CI (99.9%): [34.453, 37.855] (assumes normal distribution)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] JSQLParser Version : Trino : additional clauses in function parameters unsupported

1 participant