diff options
author | Sergei Golubchik <sergii@pisem.net> | 2012-08-27 18:13:17 +0200 |
---|---|---|
committer | Sergei Golubchik <sergii@pisem.net> | 2012-08-27 18:13:17 +0200 |
commit | 9a64d0794c3dce1652839820350a8c4b9b510e99 (patch) | |
tree | 33ebd07354a15944288a071bd9319dfa34f226ef /sql/sql_union.cc | |
parent | ced3907c02dfa3b237e14d79aa800b3a0769e94a (diff) | |
parent | e988c4dde6c1b88523b1d4e748cbd4f5025b128d (diff) | |
download | mariadb-git-9a64d0794c3dce1652839820350a8c4b9b510e99.tar.gz |
5.3 merge
Diffstat (limited to 'sql/sql_union.cc')
-rw-r--r-- | sql/sql_union.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/sql_union.cc b/sql/sql_union.cc index 021267b53bd..8dcae907926 100644 --- a/sql/sql_union.cc +++ b/sql/sql_union.cc @@ -621,6 +621,8 @@ bool st_select_lex_unit::exec() if (executed && !uncacheable && !describe) DBUG_RETURN(FALSE); executed= 1; + if (!(uncacheable & ~UNCACHEABLE_EXPLAIN) && item) + item->make_const(); saved_error= optimize(); |