mirror of
https://github.com/MariaDB/server.git
synced 2025-05-29 21:42:28 +03:00
Automerge.
This commit is contained in:
commit
2bbae9383e
@ -2501,6 +2501,17 @@ SELECT a, MAX(b) FROM t WHERE b > 0 AND b < 2 GROUP BY a;
|
|||||||
a MAX(b)
|
a MAX(b)
|
||||||
2 1
|
2 1
|
||||||
DROP TABLE t;
|
DROP TABLE t;
|
||||||
|
#
|
||||||
|
# Bug #48472: Loose index scan inappropriately chosen for some WHERE
|
||||||
|
# conditions
|
||||||
|
#
|
||||||
|
CREATE TABLE t (a INT, b INT, INDEX (a,b));
|
||||||
|
INSERT INTO t VALUES (2,0), (2,0), (2,1), (2,1);
|
||||||
|
INSERT INTO t SELECT * FROM t;
|
||||||
|
SELECT a, MAX(b) FROM t WHERE 0=b+0 GROUP BY a;
|
||||||
|
a MAX(b)
|
||||||
|
2 0
|
||||||
|
DROP TABLE t;
|
||||||
End of 5.0 tests
|
End of 5.0 tests
|
||||||
#
|
#
|
||||||
# Bug #46607: Assertion failed: (cond_type == Item::FUNC_ITEM) results in
|
# Bug #46607: Assertion failed: (cond_type == Item::FUNC_ITEM) results in
|
||||||
|
@ -1016,6 +1016,18 @@ SELECT a, MAX(b) FROM t WHERE b > 0 AND b < 2 GROUP BY a;
|
|||||||
|
|
||||||
DROP TABLE t;
|
DROP TABLE t;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # Bug #48472: Loose index scan inappropriately chosen for some WHERE
|
||||||
|
--echo # conditions
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
CREATE TABLE t (a INT, b INT, INDEX (a,b));
|
||||||
|
INSERT INTO t VALUES (2,0), (2,0), (2,1), (2,1);
|
||||||
|
INSERT INTO t SELECT * FROM t;
|
||||||
|
|
||||||
|
SELECT a, MAX(b) FROM t WHERE 0=b+0 GROUP BY a;
|
||||||
|
|
||||||
|
DROP TABLE t;
|
||||||
|
|
||||||
--echo End of 5.0 tests
|
--echo End of 5.0 tests
|
||||||
|
|
||||||
|
@ -9851,7 +9851,11 @@ check_group_min_max_predicates(COND *cond, Item_field *min_max_arg_item,
|
|||||||
}
|
}
|
||||||
else if (cur_arg->const_item())
|
else if (cur_arg->const_item())
|
||||||
{
|
{
|
||||||
DBUG_RETURN(TRUE);
|
/*
|
||||||
|
For predicates of the form "const OP expr" we also have to check 'expr'
|
||||||
|
to make a decision.
|
||||||
|
*/
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
DBUG_RETURN(FALSE);
|
DBUG_RETURN(FALSE);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user