mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
BUG#923246: Loosescan reports different result than other semijoin methods
- If LooseScan is used with quick select, require that quick select produces data in key order (this disables use of MRR, which can return data in arbitrary order).
This commit is contained in:
@@ -4099,6 +4099,11 @@ int setup_semijoin_dups_elimination(JOIN *join, ulonglong options,
|
||||
{
|
||||
/* We jump from the last table to the first one */
|
||||
tab->loosescan_match_tab= tab + pos->n_sj_tables - 1;
|
||||
|
||||
/* LooseScan requires records to be produced in order */
|
||||
if (tab->select && tab->select->quick)
|
||||
tab->select->quick->need_sorted_output();
|
||||
|
||||
for (uint j= i; j < i + pos->n_sj_tables; j++)
|
||||
join->join_tab[j].inside_loosescan_range= TRUE;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user