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

MDEV-28095 crash in multi-update and implicit grouping

disallow implicit grouping in multi-update.
explicit GROUP BY is not allowed by the grammar.
This commit is contained in:
Sergei Golubchik
2022-03-17 16:57:56 +01:00
parent 6a2d88c132
commit ecb6f9c894
3 changed files with 39 additions and 0 deletions

View File

@ -2150,6 +2150,11 @@ multi_update::initialize_tables(JOIN *join)
if (unlikely((thd->variables.option_bits & OPTION_SAFE_UPDATES) &&
error_if_full_join(join)))
DBUG_RETURN(1);
if (join->implicit_grouping)
{
my_error(ER_INVALID_GROUP_FUNC_USE, MYF(0));
DBUG_RETURN(1);
}
main_table=join->join_tab->table;
table_to_update= 0;