aboutsummaryrefslogtreecommitdiffstats
path: root/yql/essentials/tests/sql/suites/aggregate/yql-20121.sql
blob: 42c3e4aba2463087f7fd28da18849d2b00ce9924 (plain) (blame)
1
2
3
4
$s = select x,y,sum(z) as cnt from (select 1 as x, 2 as y,10 as z) group by x,y;
$s2 = select x,y,sum(cnt) from $s group by x,y;
select x,count(*) from $s2 group by x;