From 70ed9796ff8d179c577d0684ee92e74da4c29525 Mon Sep 17 00:00:00 2001 From: Ping Xiao Date: Sat, 8 May 2021 15:56:18 +0800 Subject: [PATCH] [TD-4017]: add test case --- tests/pytest/query/unionAllTest.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/pytest/query/unionAllTest.py b/tests/pytest/query/unionAllTest.py index 49d745ebd5..3064e2f63e 100644 --- a/tests/pytest/query/unionAllTest.py +++ b/tests/pytest/query/unionAllTest.py @@ -74,6 +74,16 @@ class TDTestCase: tdSql.error("select 'dc' as options from stb where type = 1 limit 1 union all select 'ad' as city from stb where type = 2 limit 1") + # for defect https://jira.taosdata.com:18080/browse/TD-4017 + tdSql.execute("alter table stb add column col int") + tdSql.execute("insert into tb1 values(%d, 'option1', 'beijing', 10)" % (self.ts + 1000)) + + tdSql.query("select 'dc' as options from stb where col > 10 limit 1") + tdSql.checkRows(0) + + tdSql.query("select 'dcs' as options from stb where col > 200 limit 1 union all select 'aaa' as options from stb limit 10") + tdSql.checkData(0, 0, 'aaa') + def stop(self): tdSql.close() tdLog.success("%s successfully executed" % __file__) -- GitLab