sql_error create table txx as select avg(c) as t from st;
sql_error create table txx as select avg(c) as t from st;
sql_error create table txx1 as select avg(c) as t from t1;
sql_error create table txx1 as select avg(c) as t from t1;
sql select stddev(c),stddev(c) from st group by c;
sql select stddev(c),stddev(c) from st group by c order by c;
if $rows != 4 then
if $rows != 4 then
return -1
return -1
endi
endi
print =================>TD-2236
print =================>TD-2236
sql select first(ts),last(ts) from t1 group by c;
sql select first(ts),last(ts) from t1 group by c order by c;
if $rows != 4 then
if $rows != 4 then
return -1
return -1
endi
endi
...
@@ -651,7 +618,7 @@ if $data31 != @20-03-27 05:10:19.000@ then
...
@@ -651,7 +618,7 @@ if $data31 != @20-03-27 05:10:19.000@ then
endi
endi
print ===============>
print ===============>
sql select stddev(c),c from st where t2=1 or t2=2 group by c;
sql select stddev(c),c from st where t2=1 or t2=2 group by c order by c;
if $rows != 4 then
if $rows != 4 then
return -1
return -1
endi
endi
...
@@ -689,14 +656,11 @@ if $data31 != 4 then
...
@@ -689,14 +656,11 @@ if $data31 != 4 then
endi
endi
sql_error select irate(c) from st where t1="1" and ts >= '2020-03-27 04:11:17.732' and ts < '2020-03-27 05:11:17.732' interval(1m) sliding(15s) group by tbname,c;
sql_error select irate(c) from st where t1="1" and ts >= '2020-03-27 04:11:17.732' and ts < '2020-03-27 05:11:17.732' interval(1m) sliding(15s) group by tbname,c;
sql select irate(c) from st where t1="1" and ts >= '2020-03-27 04:11:17.732' and ts < '2020-03-27 05:11:17.732' interval(1m) sliding(15s) group by tbname,t1,t2;
sql select _wstart, irate(c), tbname, t1, t2 from st where t1=1 and ts >= '2020-03-27 04:11:17.732' and ts < '2020-03-27 05:11:17.732' partition by tbname,t1,t2 interval(1m) sliding(15s) order by tbname;
if $rows != 40 then
if $rows != 40 then
return -1
return -1
endi
endi
if $data01 != 1.000000000 then
return -1
endi
if $data02 != t1 then
if $data02 != t1 then
return -1
return -1
endi
endi
...
@@ -707,9 +671,6 @@ if $data04 != 1 then
...
@@ -707,9 +671,6 @@ if $data04 != 1 then
return -1
return -1
endi
endi
if $data11 != 1.000000000 then
return -1
endi
if $data12 != t1 then
if $data12 != t1 then
return -1
return -1
endi
endi
...
@@ -720,21 +681,21 @@ if $data14 != 1 then
...
@@ -720,21 +681,21 @@ if $data14 != 1 then
return -1
return -1
endi
endi
sql select irate(c) from st where t1="1" and ts >= '2020-03-27 04:11:17.732' and ts < '2020-03-27 05:11:17.732' interval(1m) sliding(15s) group by tbname,t1,t2 limit 1;
sql select _wstart, irate(c), tbname, t1, t2 from st where t1=1 and ts >= '2020-03-27 04:11:17.732' and ts < '2020-03-27 05:11:17.732' partition by tbname, t1, t2 interval(1m) sliding(15s) order by tbname desc limit 1;