summaryrefslogtreecommitdiff
path: root/sql/opt_sum.cc
diff options
context:
space:
mode:
authorMichael Widenius <monty@askmonty.org>2011-09-10 18:01:27 +0300
committerMichael Widenius <monty@askmonty.org>2011-09-10 18:01:27 +0300
commit3fb22ac5e146e1fe34d282c3c3ef6bd50af90ca5 (patch)
tree4f069ae5398a3e17417f942cb6926c66efe968a6 /sql/opt_sum.cc
parent3769841d9e706ee018d5273d2901954b9a281c3e (diff)
parent0db9c26b05439f9d6fc29234966f50d8e393dfe2 (diff)
downloadmariadb-git-3fb22ac5e146e1fe34d282c3c3ef6bd50af90ca5.tar.gz
Merge with 5.2
Diffstat (limited to 'sql/opt_sum.cc')
-rw-r--r--sql/opt_sum.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/opt_sum.cc b/sql/opt_sum.cc
index 43fbe17a25b..dc93548418a 100644
--- a/sql/opt_sum.cc
+++ b/sql/opt_sum.cc
@@ -671,6 +671,8 @@ static bool matching_cond(bool max_fl, TABLE_REF *ref, KEY *keyinfo,
case Item_func::GE_FUNC:
break;
case Item_func::BETWEEN:
+ if (((Item_func_between*) cond)->negated)
+ DBUG_RETURN(FALSE);
between= 1;
break;
case Item_func::MULT_EQUAL_FUNC: