You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "jeyhunkarimov (via GitHub)" <gi...@apache.org> on 2024/02/01 09:51:01 UTC
Re: [PR] [FLINK-34111][table] Add JSON_QUOTE and JSON_UNQUOTE function [flink]
jeyhunkarimov commented on code in PR #24156:
URL: https://github.com/apache/flink/pull/24156#discussion_r1474142442
##########
flink-table/flink-table-planner/src/test/scala/org/apache/flink/table/planner/expressions/ScalarFunctionsTest.scala:
##########
@@ -604,6 +604,20 @@ class ScalarFunctionsTest extends ScalarTypesTestBase {
"foothebar")
}
+ @Test
+ def testJsonQuote(): Unit = {
+ testSqlApi("JSON_QUOTE('null')", "\"null\"")
+ testSqlApi("JSON_QUOTE('\"null\"')", "\"\\\"null\\\"\"")
+ testSqlApi("JSON_QUOTE('[1, 2, 3]')", "\"[1, 2, 3]\"")
Review Comment:
Makes sense. I updated the `json[Un]quote()` functions and tests accordingly in my last commit.
--
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: issues-unsubscribe@flink.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org