提交 015f1b82 编写于 作者: H Haojun Liao

[td-1752] add test cases.

上级 9f653eda
...@@ -91,4 +91,22 @@ endi ...@@ -91,4 +91,22 @@ endi
sql_error select max(c2*2) from $tb sql_error select max(c2*2) from $tb
sql_error select max(c1-c2) from $tb sql_error select max(c1-c2) from $tb
print =====================> td-1764
sql select sum(c1)/count(*), sum(c1) as b, count(*) as b from $stb interval(1y)
if $rows != 1 then
return -1
endi
if $data00 != @18-01-01 00:00:00.000@ then
return -1
endi
if $data01 != 2.250000000 then
return -1
endi
if $data02 != 225000 then
return -1
endi
system sh/exec.sh -n dnode1 -s stop -x SIGINT system sh/exec.sh -n dnode1 -s stop -x SIGINT
\ No newline at end of file
...@@ -251,7 +251,7 @@ if $rows != 15 then ...@@ -251,7 +251,7 @@ if $rows != 15 then
endi endi
# first subclause are empty # first subclause are empty
sql select count(*) as c from union_tb0 where ts>now+10y union all select sum(c1) as c from union_tb1; sql select count(*) as c from union_tb0 where ts > now + 3650d union all select sum(c1) as c from union_tb1;
if $rows != 1 then if $rows != 1 then
return -1 return -1
endi endi
...@@ -346,7 +346,7 @@ if $data91 != 99 then ...@@ -346,7 +346,7 @@ if $data91 != 99 then
return -1 return -1
endi endi
#1111111111111111111111111111111111111111111111111 #=================================================================================================
# two aggregated functions for normal tables # two aggregated functions for normal tables
sql select sum(c1) as a from union_tb0 limit 1 union all select sum(c3) as a from union_tb1 limit 2; sql select sum(c1) as a from union_tb0 limit 1 union all select sum(c3) as a from union_tb1 limit 2;
if $rows != 2 then if $rows != 2 then
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册