diff options
author | Monty <monty@mariadb.org> | 2020-03-18 12:00:38 +0200 |
---|---|---|
committer | Monty <monty@mariadb.org> | 2020-03-18 12:00:38 +0200 |
commit | 305cffebaba7a81fcc12f0c7511ffe639cb9b0d2 (patch) | |
tree | bc3047413379f91841457b449f84a3ac6c40678e /sql/opt_range.cc | |
parent | 36b0b302f26f59770ae12ad528e6f56c78083f4c (diff) | |
parent | 517f659e6d5eeb7e01bf19ef8b782bc2619831d4 (diff) | |
download | mariadb-git-305cffebaba7a81fcc12f0c7511ffe639cb9b0d2.tar.gz |
merge 10.4 to 10.5
Diffstat (limited to 'sql/opt_range.cc')
-rw-r--r-- | sql/opt_range.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sql/opt_range.cc b/sql/opt_range.cc index c7ec95f2071..8ce89705127 100644 --- a/sql/opt_range.cc +++ b/sql/opt_range.cc @@ -7391,6 +7391,9 @@ static TRP_RANGE *get_key_scans_params(PARAM *param, SEL_TREE *tree, found_records= check_quick_select(param, idx, read_index_only, key, update_tbl_stats, &mrr_flags, &buf_size, &cost, &is_ror_scan); + if (!is_ror_scan && + !optimizer_flag(param->thd, OPTIMIZER_SWITCH_INDEX_MERGE_SORT_UNION)) + continue; if (found_records != HA_POS_ERROR && tree->index_scans && (index_scan= (INDEX_SCAN_INFO *)alloc_root(param->mem_root, |