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

MDEV-33742 Do not create group by handler when all tables are constant

This commit is contained in:
Yuchen Pei
2024-04-08 14:28:23 +10:00
parent e865ef6a04
commit f9e0ebeca4
4 changed files with 1 additions and 7 deletions

View File

@ -3367,7 +3367,7 @@ bool JOIN::make_aggr_tables_info()
distinct in the engine, so we do this for all queries, not only
GROUP BY queries.
*/
if (tables_list && top_join_tab_count && !procedure)
if (tables_list && top_join_tab_count && !only_const_tables() && !procedure)
{
/*
At the moment we only support push down for queries where