1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

Merge 5.5->5.5-mwl248

This commit is contained in:
Igor Babaev
2012-08-14 12:42:14 -07:00
201 changed files with 6162 additions and 2267 deletions

View File

@ -11803,9 +11803,10 @@ get_best_group_min_max(PARAM *param, SEL_TREE *tree, double read_time)
have_min= TRUE;
else if (min_max_item->sum_func() == Item_sum::MAX_FUNC)
have_max= TRUE;
else if (min_max_item->sum_func() == Item_sum::COUNT_DISTINCT_FUNC ||
min_max_item->sum_func() == Item_sum::SUM_DISTINCT_FUNC ||
min_max_item->sum_func() == Item_sum::AVG_DISTINCT_FUNC)
else if (is_agg_distinct &&
(min_max_item->sum_func() == Item_sum::COUNT_DISTINCT_FUNC ||
min_max_item->sum_func() == Item_sum::SUM_DISTINCT_FUNC ||
min_max_item->sum_func() == Item_sum::AVG_DISTINCT_FUNC))
continue;
else
DBUG_RETURN(NULL);