diff options
author | Sergei Golubchik <sergii@pisem.net> | 2014-08-31 19:55:11 +0200 |
---|---|---|
committer | Sergei Golubchik <sergii@pisem.net> | 2014-08-31 19:55:11 +0200 |
commit | 6389fd3c7974a017e19142d280fb309304de5621 (patch) | |
tree | 6a731e0718b2128de7b7faba810629853ae16928 /sql/sql_show.cc | |
parent | c01c819209fdf09b4ba95f34d87d0617776f47cd (diff) | |
download | mariadb-git-6389fd3c7974a017e19142d280fb309304de5621.tar.gz |
MDEV-6673 I_S.SESSION_VARIABLES shows global values
only look at lex->option_type if it's a SHOW command, not a SELECT
Diffstat (limited to 'sql/sql_show.cc')
-rw-r--r-- | sql/sql_show.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/sql_show.cc b/sql/sql_show.cc index afbda8dd0b1..c18cc78e33e 100644 --- a/sql/sql_show.cc +++ b/sql/sql_show.cc @@ -6934,7 +6934,7 @@ int fill_variables(THD *thd, TABLE_LIST *tables, COND *cond) bool upper_case_names= (schema_table_idx != SCH_VARIABLES); bool sorted_vars= (schema_table_idx == SCH_VARIABLES); - if (lex->option_type == OPT_GLOBAL || + if ((sorted_vars && lex->option_type == OPT_GLOBAL) || schema_table_idx == SCH_GLOBAL_VARIABLES) option_type= OPT_GLOBAL; |