aboutsummaryrefslogtreecommitdiffstats
path: root/yql/essentials/tests/sql/suites/json/json_query/passing_exception.sql
diff options
context:
space:
mode:
authorrobot-piglet <robot-piglet@yandex-team.com>2024-12-27 12:59:19 +0300
committerrobot-piglet <robot-piglet@yandex-team.com>2024-12-27 13:12:33 +0300
commitc7a2519eaf60067fe973fc27f3f0c3c7d943bae9 (patch)
tree0d59847bdc681d374545fdfd0c7989f2f5a98e29 /yql/essentials/tests/sql/suites/json/json_query/passing_exception.sql
parent27df3d52304f343a3e9e87aa36b014a7a442f94e (diff)
downloadydb-c7a2519eaf60067fe973fc27f3f0c3c7d943bae9.tar.gz
Intermediate changes
commit_hash:170e724b371baded6fdcbc5f6b63da52252c1598
Diffstat (limited to 'yql/essentials/tests/sql/suites/json/json_query/passing_exception.sql')
-rw-r--r--yql/essentials/tests/sql/suites/json/json_query/passing_exception.sql16
1 files changed, 16 insertions, 0 deletions
diff --git a/yql/essentials/tests/sql/suites/json/json_query/passing_exception.sql b/yql/essentials/tests/sql/suites/json/json_query/passing_exception.sql
new file mode 100644
index 0000000000..151e6dbcd1
--- /dev/null
+++ b/yql/essentials/tests/sql/suites/json/json_query/passing_exception.sql
@@ -0,0 +1,16 @@
+/* syntax version 1 */
+/* postgres can not */
+/* custom error:Expected data or optional of data, but got: Tuple<Int32,Int32>*/
+
+$json = CAST(@@{
+ "key": 123
+}@@ as Json);
+
+-- Tuple type is not supported for variables
+SELECT
+ JSON_QUERY(
+ $json, "strict $var"
+ PASSING
+ AsTuple(1, 2) as var
+ WITH UNCONDITIONAL ARRAY WRAPPER
+ );