diff options
author | Igor Babaev <igor@askmonty.org> | 2011-12-09 14:30:50 -0800 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2011-12-09 14:30:50 -0800 |
commit | 8a09adb3eaf036b652b11afea7d9d86a978fa566 (patch) | |
tree | 4b24cdff8e3a8a41e5299373aee3428b38cbc634 /sql | |
parent | fc9d34cabf06038f930db356d53ed76dab5fdf0d (diff) | |
download | mariadb-git-8a09adb3eaf036b652b11afea7d9d86a978fa566.tar.gz |
Fixed LP bug #901312.
The function setup_sj_materialization_part1() forgot to set the value
of TABLE::map for any materialized IN subquery.
This could lead to wrong results for queries with subqueries that were
converted to queries with semijoins.
Diffstat (limited to 'sql')
-rw-r--r-- | sql/opt_subselect.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sql/opt_subselect.cc b/sql/opt_subselect.cc index 46ecb5ff65a..0819667e068 100644 --- a/sql/opt_subselect.cc +++ b/sql/opt_subselect.cc @@ -3173,6 +3173,7 @@ bool setup_sj_materialization_part1(JOIN_TAB *sjm_tab) HA_POS_ERROR /*rows_limit */, (char*)"sj-materialize"))) DBUG_RETURN(TRUE); /* purecov: inspected */ + sjm->table->map= emb_sj_nest->nested_join->used_tables; sjm->table->file->extra(HA_EXTRA_WRITE_CACHE); sjm->table->file->extra(HA_EXTRA_IGNORE_DUP_KEY); |