diff options
author | Igor Babaev <igor@askmonty.org> | 2018-04-16 16:59:19 -0700 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2018-04-16 16:59:19 -0700 |
commit | 5e61e1716e763315009318081fba5994b8910242 (patch) | |
tree | 4e587d23f540686146db5ef7685bcd32ccf04885 /sql/opt_subselect.cc | |
parent | 88ac368fea2182447284d6bacff4d93ef1acb865 (diff) | |
download | mariadb-git-5e61e1716e763315009318081fba5994b8910242.tar.gz |
MDEV-14515 ifnull result depends on number of rows in joined table
Any expensive WHERE condition for a table-less query with
implicit aggregation was lost. As a result the used aggregate
functions were calculated over a non-empty set of rows even
in the case when the condition was false.
Diffstat (limited to 'sql/opt_subselect.cc')
-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 c21541c4b97..1bda84bacd7 100644 --- a/sql/opt_subselect.cc +++ b/sql/opt_subselect.cc @@ -5903,5 +5903,6 @@ bool JOIN::choose_tableless_subquery_plan() tmp_having= having; } } + exec_const_cond= conds; return FALSE; } |