mirror of
https://github.com/MariaDB/server.git
synced 2025-09-02 09:41:40 +03:00
Fixed bug #26830: a crash for the query with a subselect containing ROLLUP.
Crash happened because the function get_best_group_min_max detected joins with ROLLUP incorrectly.
This commit is contained in:
@@ -645,3 +645,12 @@ a LENGTH(a) COUNT(*)
|
||||
NULL NULL 2
|
||||
DROP VIEW v1;
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (a int, KEY (a));
|
||||
INSERT INTO t1 VALUES (3), (1), (4), (1), (3), (1), (1);
|
||||
SELECT * FROM (SELECT a, SUM(a) FROM t1 GROUP BY a WITH ROLLUP) as t;
|
||||
a SUM(a)
|
||||
1 4
|
||||
3 6
|
||||
4 4
|
||||
NULL 14
|
||||
DROP TABLE t1;
|
||||
|
Reference in New Issue
Block a user