summaryrefslogtreecommitdiff
path: root/sql/sql_yacc.yy
diff options
context:
space:
mode:
authorIgor Babaev <igor@askmonty.org>2017-02-01 19:15:28 -0800
committerIgor Babaev <igor@askmonty.org>2017-02-01 19:15:28 -0800
commit8481c70ede067b576d5b1576a9b68042e84368fb (patch)
tree568c142550bde93e45e7d5a39ae32cff42b2a7cf /sql/sql_yacc.yy
parent69114862f21dadb5c660847c691cc24456c90970 (diff)
downloadmariadb-git-8481c70ede067b576d5b1576a9b68042e84368fb.tar.gz
Fixed bug mdev-11867.
If a window function with aggregation is over the result set of a grouping query then the argument of the aggregate function from the window function is allowed to be an aggregate function itself.
Diffstat (limited to 'sql/sql_yacc.yy')
-rw-r--r--sql/sql_yacc.yy3
1 files changed, 3 insertions, 0 deletions
diff --git a/sql/sql_yacc.yy b/sql/sql_yacc.yy
index 0cd2c563319..12423e71f1f 100644
--- a/sql/sql_yacc.yy
+++ b/sql/sql_yacc.yy
@@ -10464,6 +10464,9 @@ window_func:
simple_window_func
|
sum_expr
+ {
+ ((Item_sum *) $1)->mark_as_window_func_sum_expr();
+ }
;
simple_window_func: