summaryrefslogtreecommitdiff
path: root/sql/sql_class.h
diff options
context:
space:
mode:
Diffstat (limited to 'sql/sql_class.h')
-rw-r--r--sql/sql_class.h9
1 files changed, 3 insertions, 6 deletions
diff --git a/sql/sql_class.h b/sql/sql_class.h
index 88d3af04376..b377d74445f 100644
--- a/sql/sql_class.h
+++ b/sql/sql_class.h
@@ -3959,12 +3959,9 @@ public:
my_message(ER_NO_DB_ERROR, ER(ER_NO_DB_ERROR), MYF(0));
return TRUE;
}
- /*
- It does not matter what database name is set in this case
- because it will never be used after parser stage
- */
- *p_db_length= strlen(no_db);
- *p_db= strmake(no_db, *p_db_length);
+ /* This will allow to throw an error later for non-CTE references */
+ *p_db= NULL;
+ *p_db_length= 0;
}
else
{