You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by yi...@apache.org on 2022/12/16 13:57:42 UTC
[doris] branch master updated: [regression-test](query) Add regression case of error could not be changed to nullabl when exe… (#15123)
This is an automated email from the ASF dual-hosted git repository.
yiguolei pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/master by this push:
new 33abe11dea [regression-test](query) Add regression case of error could not be changed to nullabl when exe… (#15123)
33abe11dea is described below
commit 33abe11dea8b8dfddcb6d57d045c6b87fc6beb7f
Author: Hong Liu <84...@qq.com>
AuthorDate: Fri Dec 16 21:57:36 2022 +0800
[regression-test](query) Add regression case of error could not be changed to nullabl when exe… (#15123)
* Add regression case of error could not be changed to nullabl when exeing sql
* add out file
Co-authored-by: smallhibiscus <844981280>
---
.../data/query_p0/join/test_left_join1.out | 7 ++++
.../suites/query_p0/join/ddl/test_left_join1.sql | 12 +++++++
.../suites/query_p0/join/test_left_join1.groovy | 42 ++++++++++++++++++++++
3 files changed, 61 insertions(+)
diff --git a/regression-test/data/query_p0/join/test_left_join1.out b/regression-test/data/query_p0/join/test_left_join1.out
new file mode 100644
index 0000000000..7f19a1333e
--- /dev/null
+++ b/regression-test/data/query_p0/join/test_left_join1.out
@@ -0,0 +1,7 @@
+-- This file is automatically generated. You should know what you did if you want to edit this
+-- !select --
+1 123 1 123 \N \N
+2 124 2 124 2 124
+3 125 3 125 3 125
+4 126 4 126 4 126
+
diff --git a/regression-test/suites/query_p0/join/ddl/test_left_join1.sql b/regression-test/suites/query_p0/join/ddl/test_left_join1.sql
new file mode 100644
index 0000000000..1ecda88e6d
--- /dev/null
+++ b/regression-test/suites/query_p0/join/ddl/test_left_join1.sql
@@ -0,0 +1,12 @@
+CREATE TABLE `test_left_join1` (
+ `f_key` bigint(10) NOT NULL DEFAULT "0" COMMENT "key",
+ `f_value` bigint(10) REPLACE_IF_NOT_NULL NULL COMMENT "value"
+) ENGINE=OLAP
+AGGREGATE KEY(`f_key`)
+COMMENT "向量引擎bug展示"
+DISTRIBUTED BY HASH(`f_key`) BUCKETS 2
+PROPERTIES (
+ "replication_allocation" = "tag.location.default: 1",
+ "in_memory" = "false",
+ "storage_format" = "V2"
+);
diff --git a/regression-test/suites/query_p0/join/test_left_join1.groovy b/regression-test/suites/query_p0/join/test_left_join1.groovy
new file mode 100644
index 0000000000..d4cbeeee65
--- /dev/null
+++ b/regression-test/suites/query_p0/join/test_left_join1.groovy
@@ -0,0 +1,42 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+suite("test_left_join1", "query,p0") {
+
+ def tableName = "test_left_join1"
+ sql """drop table if exists ${tableName}"""
+ sql new File("""${context.file.parent}/ddl/test_left_join1.sql""").text
+
+ sql """insert into ${tableName} values (1, 123),(2, 124),(3, 125),(4, 126);"""
+
+ qt_select """ SELECT
+ *
+ FROM
+ ( SELECT f_key, f_value FROM ${tableName} ) a
+ LEFT JOIN ( SELECT f_key, f_value FROM ${tableName} ) b ON a.f_key = b.f_key
+ LEFT JOIN (
+ SELECT
+ *
+ FROM
+ ${tableName}
+ WHERE
+ f_key IN ( SELECT f_key FROM ${tableName} WHERE f_key IN ( SELECT f_key FROM ${tableName} WHERE f_value > 123 ) )
+ ) c ON a.f_key = c.f_key
+ ORDER BY
+ a.f_key;
+ """
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org