mirror of
https://github.com/MariaDB/server.git
synced 2025-08-05 13:16:09 +03:00
Bug #7966 query cache doesn't work properly with batch statements
sql_lex.cc: Set query to not cacheable if we are using multistatements and there are multiple statements in this query sql/sql_lex.cc: Set query to not cacheable if we are using multistatements and there are multiple statements in this query
This commit is contained in:
@@ -912,6 +912,7 @@ int yylex(void *arg, void *yythd)
|
|||||||
if ((thd->client_capabilities & CLIENT_MULTI_STATEMENTS) &&
|
if ((thd->client_capabilities & CLIENT_MULTI_STATEMENTS) &&
|
||||||
(thd->command != COM_PREPARE))
|
(thd->command != COM_PREPARE))
|
||||||
{
|
{
|
||||||
|
lex->safe_to_cache_query=0;
|
||||||
lex->found_colon=(char*)lex->ptr;
|
lex->found_colon=(char*)lex->ptr;
|
||||||
thd->server_status |= SERVER_MORE_RESULTS_EXISTS;
|
thd->server_status |= SERVER_MORE_RESULTS_EXISTS;
|
||||||
lex->next_state=MY_LEX_END;
|
lex->next_state=MY_LEX_END;
|
||||||
|
Reference in New Issue
Block a user