summaryrefslogtreecommitdiff
path: root/sql/opt_sum.cc
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2021-03-20 13:04:36 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2021-03-20 13:04:36 +0200
commitd8dc8537e4f6cfb3b0c63123a8d9df5c1101970d (patch)
tree036edbea930caa77afe4fb2a8acef9242b54805b /sql/opt_sum.cc
parent550cf13eb3e8a25826a0fa67935fc28ee7adb0c8 (diff)
parent0f3045e4329d900cc95f84b5fe9ff5c9d96240c7 (diff)
downloadmariadb-git-d8dc8537e4f6cfb3b0c63123a8d9df5c1101970d.tar.gz
Merge 10.3 into 10.4
Diffstat (limited to 'sql/opt_sum.cc')
-rw-r--r--sql/opt_sum.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/sql/opt_sum.cc b/sql/opt_sum.cc
index af2d9ddc2e7..27360d4a10c 100644
--- a/sql/opt_sum.cc
+++ b/sql/opt_sum.cc
@@ -842,7 +842,10 @@ static bool matching_cond(bool max_fl, TABLE_REF *ref, KEY *keyinfo,
if (is_field_part)
{
if (between || eq_type)
+ {
*range_fl&= ~(NO_MAX_RANGE | NO_MIN_RANGE);
+ *range_fl&= ~(max_fl ? NEAR_MAX : NEAR_MIN);
+ }
else
{
*range_fl&= ~(max_fl ? NO_MAX_RANGE : NO_MIN_RANGE);