mirror of
https://github.com/MariaDB/server.git
synced 2026-05-09 00:24:30 +02:00
several bug fixes and tests
mysql-test/mysql-test-run.sh: Fix for LOAD DATA LOCAL ... mysql-test/r/select_found.result: Added result for a new test of combo of options for FOUND_ROWS and BUFFER_RESULT mysql-test/t/select_found.test: Added test for combo of options for BUFFER_RESULT and FOUND_ROWS sql/sql_select.cc: Added fix for combo of options for BUFFER_RESULT and FOUND_ROWS
This commit is contained in:
parent
d737186f30
commit
a02a98c401
4 changed files with 13 additions and 3 deletions
|
|
@ -187,7 +187,7 @@ mysql_select(THD *thd,TABLE_LIST *tables,List<Item> &fields,COND *conds,
|
|||
TABLE *tmp_table;
|
||||
int error, tmp_error;
|
||||
bool need_tmp,hidden_group_fields;
|
||||
bool simple_order,simple_group,no_order, skip_sort_order;
|
||||
bool simple_order,simple_group,no_order, skip_sort_order, buffer_result;
|
||||
Item::cond_result cond_value;
|
||||
SQL_SELECT *select;
|
||||
DYNAMIC_ARRAY keyuse;
|
||||
|
|
@ -201,6 +201,7 @@ mysql_select(THD *thd,TABLE_LIST *tables,List<Item> &fields,COND *conds,
|
|||
/* Check that all tables, fields, conds and order are ok */
|
||||
|
||||
select_distinct=test(select_options & SELECT_DISTINCT);
|
||||
buffer_result=test(select_options & OPTION_BUFFER_RESULT) && !test(select_options & OPTION_FOUND_ROWS);
|
||||
tmp_table=0;
|
||||
select=0;
|
||||
no_order=skip_sort_order=0;
|
||||
|
|
@ -546,8 +547,7 @@ mysql_select(THD *thd,TABLE_LIST *tables,List<Item> &fields,COND *conds,
|
|||
|
||||
need_tmp= (join.const_tables != join.tables &&
|
||||
((select_distinct || !simple_order || !simple_group) ||
|
||||
(group && order) ||
|
||||
test(select_options & OPTION_BUFFER_RESULT)));
|
||||
(group && order) || buffer_result));
|
||||
|
||||
// No cache for MATCH
|
||||
make_join_readinfo(&join,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue