diff options
author | Igor Babaev <igor@askmonty.org> | 2014-10-14 09:36:50 -0700 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2014-10-14 09:36:50 -0700 |
commit | 3c4bb0e8720b84a14fe4822d1986d01290b9ab44 (patch) | |
tree | e474ca9e76d09e770c4e3d5c37e3161d1cc42ace /sql/opt_subselect.cc | |
parent | fec5ab5a56cb9a45c621207620cc85079cddf537 (diff) | |
download | mariadb-git-3c4bb0e8720b84a14fe4822d1986d01290b9ab44.tar.gz |
MDEV-334: Backport of UNION ALL optimization from mysql-5.7.
Although the original code of mysql-5.7 was adjusted
to the current MariaDB code the main ideas of the optimization
were preserved.
Diffstat (limited to 'sql/opt_subselect.cc')
-rw-r--r-- | sql/opt_subselect.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sql/opt_subselect.cc b/sql/opt_subselect.cc index 4902ae8b028..66b1ba16cbc 100644 --- a/sql/opt_subselect.cc +++ b/sql/opt_subselect.cc @@ -5224,7 +5224,7 @@ bool setup_jtbm_semi_joins(JOIN *join, List<TABLE_LIST> *join_list, if (!(new_sink= new select_value_catcher(subq_pred))) DBUG_RETURN(TRUE); if (new_sink->setup(&engine->select_lex->join->fields_list) || - engine->select_lex->join->change_result(new_sink) || + engine->select_lex->join->change_result(new_sink, NULL) || engine->exec()) { DBUG_RETURN(TRUE); @@ -5576,8 +5576,8 @@ bool JOIN::choose_subquery_plan(table_map join_tables) Item_in_subselect::test_limit). However, once we allow this, here we should set the correct limit if given in the query. */ - in_subs->unit->global_parameters->select_limit= NULL; - in_subs->unit->set_limit(unit->global_parameters); + in_subs->unit->global_parameters()->select_limit= NULL; + in_subs->unit->set_limit(unit->global_parameters()); /* Set the limit of this JOIN object as well, because normally its being set in the beginning of JOIN::optimize, which was already done. |