Commit 1a490f2d authored by Sergey Petrunya's avatar Sergey Petrunya

DS-MRR backport: fix buildbot valgrind failures:

- Do call update_used_tables() for new conditions obtained when adding
  outer join's triggered conditions. Correct values of used_tables() are
  now needed for condition pushdown.
- Update test results

mysql-test/suite/pbxt/r/join_outer.result:
  DS-MRR backport:
  - Update test results
sql/sql_select.cc:
  DS-MRR backport: fix buildbot valgrind failures:
  - Do call update_used_tables() for new conditions obtained when adding
    outer join's triggered conditions. Correct values of used_tables() are
    now needed for condition pushdown.
parent 18fc4a77
......@@ -886,7 +886,7 @@ EXPLAIN SELECT * FROM t0, t1 LEFT JOIN (t2,t3) ON a1=5 WHERE a0=a1 AND a0=1;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t0 const PRIMARY PRIMARY 4 const 1 Using index
1 SIMPLE t1 const PRIMARY PRIMARY 4 const 1 Using index
1 SIMPLE t2 ALL NULL NULL NULL NULL 2
1 SIMPLE t2 ALL NULL NULL NULL NULL 2 Using where
1 SIMPLE t3 ALL NULL NULL NULL NULL 2
drop table t1,t2;
create table t1 (a int, b int);
......
......@@ -6201,6 +6201,7 @@ make_join_select(JOIN *join,SQL_SELECT *select,COND *cond)
cond_tab->set_select_cond(new_cond, __LINE__);
if (!cond_tab->select_cond)
DBUG_RETURN(1);
cond_tab->select_cond->update_used_tables();
cond_tab->select_cond->quick_fix_field();
}
}
......@@ -6482,6 +6483,7 @@ make_join_select(JOIN *join,SQL_SELECT *select,COND *cond)
if (!cond_tab->select_cond)
DBUG_RETURN(1);
cond_tab->select_cond->quick_fix_field();
cond_tab->select_cond->update_used_tables();
if (cond_tab->select)
cond_tab->select->cond= cond_tab->select_cond;
}
......@@ -6537,6 +6539,7 @@ make_join_select(JOIN *join,SQL_SELECT *select,COND *cond)
(ulong)cond_tab->select_cond));
if (!cond_tab->select_cond)
DBUG_RETURN(1);
cond_tab->select_cond->update_used_tables();
cond_tab->select_cond->quick_fix_field();
if (cond_tab->select)
cond_tab->select->cond= cond_tab->select_cond;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment