From c47c56452680e1bbdaa9d8ed4203470cf7f02c56 Mon Sep 17 00:00:00 2001 From: unknown Date: Sat, 31 May 2003 18:31:57 +0300 Subject: Fix for the optimiser problem caused by the fact that with derived tables one (or more tables) is opened / closed twice. --- sql/sql_derived.cc | 2 ++ 1 file changed, 2 insertions(+) (limited to 'sql/sql_derived.cc') diff --git a/sql/sql_derived.cc b/sql/sql_derived.cc index 7f555f37d40..66b8048996f 100644 --- a/sql/sql_derived.cc +++ b/sql/sql_derived.cc @@ -219,6 +219,8 @@ int mysql_derived(THD *thd, LEX *lex, SELECT_LEX_UNIT *unit, /* Add new temporary table to list of open derived tables */ table->next= thd->derived_tables; thd->derived_tables= table; + thd->query_id++; + query_id++; } exit: -- cgit v1.2.1