diff options
author | Sergei Petrunia <psergey@askmonty.org> | 2016-02-09 01:46:53 +0300 |
---|---|---|
committer | Sergei Petrunia <psergey@askmonty.org> | 2016-02-09 01:46:53 +0300 |
commit | d443d70d06e39b0054b1c9beb00dceac2618c167 (patch) | |
tree | f0574350d00a2b44d148b8b62a80d80981ed7b7c /sql/sql_select.cc | |
parent | c4cb24006139bb6a619ca9d6b00d00c2275d2c28 (diff) | |
download | mariadb-git-d443d70d06e39b0054b1c9beb00dceac2618c167.tar.gz |
MDEV-7823: Server crashes in next_depth_first_tab on nested IN clauses with SQ inside
Consider a query with subquery in form t.key=(select ...). Suppose, the
parent query uses this equality for ref access.
It will attempt to evaluate the subquery in get_best_combination(),
right before the join->join_tab[...] array is filled. The problem was
that subquery optimization will attempt to look at parent's join->join_tab
to check how many times subquery will be executed (and crash).
Fixed by not doing that when the subquery is constant (non-constant
subqueries are only be evaluated during join execution, so they are not
affected)
Diffstat (limited to 'sql/sql_select.cc')
0 files changed, 0 insertions, 0 deletions