sql_error select sample(f1,2) from st2 group by f1 having count(f2) > 0;
sql_error select top(f1,2) from st2 group by f1 having count(f2) > 0;
sql select last(f1) from st2 group by f1 having count(f2) > 0;
...
...
@@ -140,9 +141,12 @@ if $data30 != 4 then
return -1
endi
sql_error select top(f1,2) from st2 group by f1 having count(f2) > 0;
sql_error select top(f1,2) from st2 group by f1 having count(f2) > 0;
sql_error select top(f1,2) from st2 group by f1 having avg(f1) > 0;
sql_error select sample(f1,2) from st2 group by f1 having count(f2) > 0;
sql_error select sample(f1,2) from st2 group by f1 having count(f2) > 0;
sql_error select sample(f1,2) from st2 group by f1 having avg(f1) > 0;
sql_error select sample(f1,2) from st2 group by f1 having count(f2) > 0;
sql_error select sample(f1,2) from st2 group by f1 having count(f2) > 0;
sql_error select sample(f1,2) from st2 group by f1 having avg(f1) > 0;
sql select avg(f1),count(f1) from st2 group by f1 having avg(f1) > 2;
if $rows != 2 then
...
...
@@ -1059,6 +1063,13 @@ if $data26 != 4 then
endi
sql_error select avg(f1),count(st2.*),sum(f1),stddev(f1),min(f1),max(f1),first(f1),last(f1) from st2 group by f1 having sample(f1,1);
sql_error select avg(f1),count(st2.*),sum(f1),stddev(f1),min(f1),max(f1),first(f1),last(f1) from st2 group by f1 having sample(f1,1) > 1;
sql_error select avg(f1),count(st2.*),sum(f1),stddev(f1),min(f1),max(f1),first(f1),last(f1),sample(f1,1) from st2 group by f1 having sum(f1) > 1;
sql_error select avg(f1),count(st2.*),sum(f1),stddev(f1),min(f1),max(f1),first(f1),last(f1),sample(f1,1),bottom(f1,1) from st2 group by f1 having bottom(f1,1) > 1;
sql_error select avg(f1),count(st2.*),sum(f1),stddev(f1),min(f1),max(f1),first(f1),last(f1) from st2 group by f1 having top(f1,1);
...
...
@@ -1149,6 +1160,18 @@ sql_error select avg(f1),diff(f1) from st2 group by f1 having avg(f1) > 0;
sql_error select avg(f1),diff(f1) from st2 group by f1 having spread(f2) > 0;
sql_error select avg(f1) from st2 group by f1 having mavg(f1, 2) > 0;
sql_error select avg(f1),mavg(f1, 3) from st2 group by f1 having avg(f1) > 0;
sql_error select avg(f1),mavg(f1, 4) from st2 group by f1 having spread(f2) > 0;
sql_error select avg(f1) from st2 group by f1 having csum(f1) > 0;
sql_error select avg(f1),csum(f1) from st2 group by f1 having avg(f1) > 0;
sql_error select avg(f1),csum(f1) from st2 group by f1 having spread(f2) > 0;
sql select avg(f1) from st2 group by f1 having spread(f2) > 0;
if $rows != 0 then
return -1
...
...
@@ -1834,6 +1857,7 @@ if $data04 != 1 then
return -1
endi
sql_error select sample(f1,2) from tb1 group by f1 having count(f1) > 0;
sql_error select top(f1,2) from tb1 group by f1 having count(f1) > 0;
sql_error select count(*) from tb1 group by f1 having last(*) > 0;
sql_error select top(f1,2) from tb1 group by f1 having count(f2) > 0;
sql_error select sample(f1,2) from tb1 group by f1 having count(f2) > 0;
sql select last(f1) from tb1 group by f1 having count(f2) > 0;
if $rows != 4 then
...
...
@@ -144,6 +145,12 @@ sql_error select top(f1,2) from tb1 group by f1 having count(f2) > 0;
sql_error select top(f1,2) from tb1 group by f1 having avg(f1) > 0;
sql_error select sample(f1,2) from tb1 group by f1 having count(f2) > 0;
sql_error select sample(f1,2) from tb1 group by f1 having count(f2) > 0;
sql_error select sample(f1,2) from tb1 group by f1 having avg(f1) > 0;
sql select avg(f1),count(f1) from tb1 group by f1 having avg(f1) > 2;
if $rows != 2 then
return -1
...
...
@@ -1067,7 +1074,13 @@ if $data26 != 4 then
return -1
endi
sql_error select avg(f1),count(tb1.*),sum(f1),stddev(f1),min(f1),max(f1),first(f1),last(f1) from tb1 group by f1 having sample(f1,1);
sql_error select avg(f1),count(tb1.*),sum(f1),stddev(f1),min(f1),max(f1),first(f1),last(f1) from tb1 group by f1 having sample(f1,1) > 1;
sql_error select avg(f1),count(tb1.*),sum(f1),stddev(f1),min(f1),max(f1),first(f1),last(f1),sample(f1,1),bottom(f1,1) from tb1 group by f1 having bottom(f1,1) > 1;
sql_error select avg(f1),count(tb1.*),sum(f1),stddev(f1),min(f1),max(f1),first(f1),last(f1),sample(f1,1),bottom(f1,1) from tb1 group by f1 having sum(f1) > 1;
sql_error select avg(f1),count(tb1.*),sum(f1),stddev(f1),min(f1),max(f1),first(f1),last(f1) from tb1 group by f1 having top(f1,1);
...
...
@@ -1164,6 +1177,20 @@ sql_error select avg(f1),diff(f1) from tb1 group by f1 having avg(f1) > 0;
sql_error select avg(f1),diff(f1) from tb1 group by f1 having spread(f2) > 0;
sql_error select avg(f1) from tb1 group by f1 having mavg(f1,4) > 0;
sql_error select avg(f1),mavg(f1,5) from tb1 group by f1 having avg(f1) > 0;
sql_error select avg(f1),mavg(f1,6) from tb1 group by f1 having spread(f2) > 0;
sql_error select avg(f1) from tb1 group by f1 having csum(f1) > 0;
sql_error select avg(f1),csum(f1) from tb1 group by f1 having avg(f1) > 0;
sql_error select avg(f1),csum(f1) from tb1 group by f1 having spread(f2) > 0;
sql select avg(f1) from tb1 group by f1 having spread(f2) > 0;
if $rows != 0 then
return -1
...
...
@@ -1857,4 +1884,6 @@ endi
sql_error select top(f1,2) from tb1 group by f1 having count(f1) > 0;
sql_error select sample(f1,2) from tb1 group by f1 having count(f1) > 0;