[td-1752] add test cases.
This commit is contained in:
parent
9f653edacd
commit
015f1b82c5
|
@ -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
|
|
@ -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
|
||||||
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
|
||||||
|
|
Loading…
Reference in New Issue