diff options
author | Igor Babaev <igor@askmonty.org> | 2017-02-02 17:57:55 -0800 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2017-02-02 18:01:35 -0800 |
commit | 5606f878bf0cc0c4c589f15c5068a9cc0bb2d197 (patch) | |
tree | 11915751512e1deb0a4c4b42e5b24382ca13c5dd /mysql-test/r/win.result | |
parent | d123ed852a2992a6cbaf65eb4cda741ace2628e2 (diff) | |
download | mariadb-git-5606f878bf0cc0c4c589f15c5068a9cc0bb2d197.tar.gz |
Fixed bug mdev-11594.
Using window functions over results of implicit groupings
required special handling in JOIN::make_aggr_tables_info.
The patch made sure that the result of implicit grouping
was written into a temporary table properly.
Diffstat (limited to 'mysql-test/r/win.result')
-rw-r--r-- | mysql-test/r/win.result | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/mysql-test/r/win.result b/mysql-test/r/win.result index 0606737c3ef..44300579411 100644 --- a/mysql-test/r/win.result +++ b/mysql-test/r/win.result @@ -2460,3 +2460,15 @@ username sum(amount) avg(sum(amount)) over (order by sum(amount) desc) user1 9 34.5000 user2 60 60.0000 drop table t1; +# +# MDEV-11594: window function over implicit grouping +# +create table test.t1 (id int); +insert into test.t1 values (1), (2), (3), (2); +select sum(id) over (order by sum(id)) from t1; +sum(id) over (order by sum(id)) +1 +select sum(sum(id)) over (order by sum(id)) from t1; +sum(sum(id)) over (order by sum(id)) +8 +drop table t1; |