diff options
author | monty@mysql.com <> | 2005-01-18 04:03:26 +0200 |
---|---|---|
committer | monty@mysql.com <> | 2005-01-18 04:03:26 +0200 |
commit | 502ba93b38cfeae6b291e5618595f9b2ee33a28f (patch) | |
tree | bb697cb498858b14ae0d525938dd3fcd68d13eaa /sql | |
parent | 88b1fbaf2f49c33d44721d7c51a46c7c121292f3 (diff) | |
parent | edffca827e40635a3738f7e5b4251033e485f024 (diff) | |
download | mariadb-git-502ba93b38cfeae6b291e5618595f9b2ee33a28f.tar.gz |
Merge with global tree
Diffstat (limited to 'sql')
-rw-r--r-- | sql/filesort.cc | 3 | ||||
-rw-r--r-- | sql/sql_lex.cc | 1 | ||||
-rw-r--r-- | sql/sql_select.cc | 2 |
3 files changed, 5 insertions, 1 deletions
diff --git a/sql/filesort.cc b/sql/filesort.cc index ecde74e5ec6..0e9fa8c79ed 100644 --- a/sql/filesort.cc +++ b/sql/filesort.cc @@ -847,7 +847,10 @@ int merge_many_buff(SORTPARAM *param, uchar *sort_buffer, } close_cached_file(to_file); // This holds old result if (to_file == t_file) + { *t_file=t_file2; // Copy result file + setup_io_cache(t_file); + } DBUG_RETURN(*maxbuffer >= MERGEBUFF2); /* Return 1 if interrupted */ } /* merge_many_buff */ diff --git a/sql/sql_lex.cc b/sql/sql_lex.cc index 495fa4a0bd1..2f6e74225fd 100644 --- a/sql/sql_lex.cc +++ b/sql/sql_lex.cc @@ -944,6 +944,7 @@ int yylex(void *arg, void *yythd) if ((thd->client_capabilities & CLIENT_MULTI_STATEMENTS) && (thd->command != COM_PREPARE)) { + lex->safe_to_cache_query= 0; lex->found_colon= (char*) lex->ptr; thd->server_status|= SERVER_MORE_RESULTS_EXISTS; lex->next_state= MY_LEX_END; diff --git a/sql/sql_select.cc b/sql/sql_select.cc index cf02d1c4f6e..94a2390324c 100644 --- a/sql/sql_select.cc +++ b/sql/sql_select.cc @@ -10443,7 +10443,7 @@ test_if_skip_sort_order(JOIN_TAB *tab,ORDER *order,ha_rows select_limit, HA_POS_ERROR : tab->join->unit->select_limit_cnt) <= 0) DBUG_RETURN(0); } - ref_key= new_ref_key; + ref_key= new_ref_key; } } /* Check if we get the rows in requested sorted order by using the key */ |