summaryrefslogtreecommitdiff
path: root/sql/sql_cursor.cc
diff options
context:
space:
mode:
Diffstat (limited to 'sql/sql_cursor.cc')
-rw-r--r--sql/sql_cursor.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/sql_cursor.cc b/sql/sql_cursor.cc
index fd348e0b75f..6a664e4d20b 100644
--- a/sql/sql_cursor.cc
+++ b/sql/sql_cursor.cc
@@ -118,6 +118,8 @@ int mysql_open_cursor(THD *thd, select_result *result,
2);
parent_locker= thd->m_statement_psi;
thd->m_statement_psi= NULL;
+ /* Mark that we can't use query cache with cursors */
+ thd->query_cache_is_applicable= 0;
rc= mysql_execute_command(thd);
thd->m_statement_psi= parent_locker;
MYSQL_QUERY_EXEC_DONE(rc);