diff options
author | Igor Babaev <igor@askmonty.org> | 2020-02-18 22:49:42 -0800 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2020-02-18 22:51:07 -0800 |
commit | 2fb881df1d89b27521ac50a6f6f5c1426536e70b (patch) | |
tree | 67dbf1a361fff37ae07df39019d47f8ba6470361 /sql/opt_range.cc | |
parent | df07e00a810890f6f6eb1334c76ee22133750777 (diff) | |
download | mariadb-git-2fb881df1d89b27521ac50a6f6f5c1426536e70b.tar.gz |
MDEV-21610 Different query results from 10.4.11 to 10.4.12
This patch fixes the following defects/bugs.
1. If BKA[H] algorithm was used to join a table for which the optimizer
had decided to employ a rowid filter the filter actually was not built.
2. The patch for the bug MDEV-21356 that added the code canceling pushing
rowid filter into an engine for the table joined with employment of
BKA[H] and MRR was not quite correct for Innodb engine because this
cancellation was done after InnoDB code had already bound the the pushed
filter to internal InnoDB structures.
Diffstat (limited to 'sql/opt_range.cc')
-rw-r--r-- | sql/opt_range.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sql/opt_range.cc b/sql/opt_range.cc index c3b82827291..bff770fdc00 100644 --- a/sql/opt_range.cc +++ b/sql/opt_range.cc @@ -2902,7 +2902,8 @@ int SQL_SELECT::test_quick_select(THD *thd, key_map keys_to_use, remove_nonrange_trees(¶m, tree); /* Get best 'range' plan and prepare data for making other plans */ - if ((range_trp= get_key_scans_params(¶m, tree, FALSE, TRUE, + if ((range_trp= get_key_scans_params(¶m, tree, + only_single_index_range_scan, TRUE, best_read_time))) { best_trp= range_trp; |