1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00

Merge 10.2 into 10.3

This commit is contained in:
Marko Mäkelä
2022-02-25 10:43:38 +02:00
41 changed files with 1403 additions and 593 deletions

View File

@ -23766,7 +23766,9 @@ int setup_order(THD *thd, Ref_ptr_array ref_pointer_array, TABLE_LIST *tables,
an ORDER BY clause
*/
if (for_union && (*order->item)->with_sum_func)
if (for_union &&
((*order->item)->with_sum_func ||
(*order->item)->with_window_func))
{
my_error(ER_AGGREGATE_ORDER_FOR_UNION, MYF(0), number);
return 1;