summaryrefslogtreecommitdiff
path: root/sql
diff options
context:
space:
mode:
authorSergei Petrunia <psergey@askmonty.org>2014-12-02 00:18:57 +0300
committerSergei Petrunia <psergey@askmonty.org>2014-12-02 00:18:57 +0300
commit54392f0a223121fd95ae00590370909415dbdd96 (patch)
tree75c1ce624ce30b1bba1202b5415080b7898a31a6 /sql
parentbf3b4a23f75de50e0f1ab4a562e5801dabc7305b (diff)
downloadmariadb-git-54392f0a223121fd95ae00590370909415dbdd96.tar.gz
MDEV-7245: Incorrect display of subquery cache in union.result
- Do set nest_level and nest_level_base for fake_select_lex objects.
Diffstat (limited to 'sql')
-rw-r--r--sql/sql_parse.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc
index 5af700b6917..0a2fd970f81 100644
--- a/sql/sql_parse.cc
+++ b/sql/sql_parse.cc
@@ -7757,6 +7757,9 @@ bool st_select_lex_unit::add_fake_select_lex(THD *thd_arg)
fake_select_lex->context.resolve_in_select_list= TRUE;
fake_select_lex->context.select_lex= fake_select_lex;
+ fake_select_lex->nest_level_base= first_select()->nest_level_base;
+ fake_select_lex->nest_level=first_select()->nest_level;
+
if (!is_union())
{
/*