mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
Fixed bug in SQL_SELECT_LIMIT
We where comparing costs when we should be comparing number of rows that will be examined
This commit is contained in:
@@ -2621,7 +2621,7 @@ int JOIN::optimize_stage2()
|
||||
goto setup_subq_exit;
|
||||
}
|
||||
if (!(thd->variables.option_bits & OPTION_BIG_SELECTS) &&
|
||||
best_read > (double) thd->variables.max_join_size &&
|
||||
join_record_count > (double) thd->variables.max_join_size &&
|
||||
!(select_options & SELECT_DESCRIBE))
|
||||
{ /* purecov: inspected */
|
||||
my_message(ER_TOO_BIG_SELECT, ER_THD(thd, ER_TOO_BIG_SELECT), MYF(0));
|
||||
|
Reference in New Issue
Block a user