diff options
| author | Varun Gupta <varunraiko1803@gmail.com> | 2018-11-01 14:26:13 +0530 |
|---|---|---|
| committer | Varun Gupta <varunraiko1803@gmail.com> | 2018-11-01 14:27:24 +0530 |
| commit | e60cbbbda31d7a10e87c16313171b2036a4519c4 (patch) | |
| tree | 89f601857b1c6e0e861c801520cad389895d8080 /mysql-test/t/group_by.test | |
| parent | f8268f3cce4577c28ab62e53293556d05a74fb1a (diff) | |
| download | mariadb-git-10.2-mdev12575.tar.gz | |
MDEV-12575: Server crash in AGGR_OP::put_record or in JOIN_CACHE::free or Invalid write in JOIN::make_aggr_tables_info10.2-mdev12575
During the optimize state of a query, we come know that the result set
would atmost contain one row, then for such a query we don't need
to compute GROUP BY, ORDER BY and DISTINCT.
Diffstat (limited to 'mysql-test/t/group_by.test')
| -rw-r--r-- | mysql-test/t/group_by.test | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/mysql-test/t/group_by.test b/mysql-test/t/group_by.test index 275939df5c5..61be676bb11 100644 --- a/mysql-test/t/group_by.test +++ b/mysql-test/t/group_by.test @@ -1948,3 +1948,15 @@ insert into t1 values(-126,7),(1,1),(0,0),(-1,1),(351,65534); select distinct 1 from t1 group by a,b with rollup limit 1; drop table t1; +# +# MDEV-12575: Server crash in AGGR_OP::put_record or in JOIN_CACHE::free +# or Invalid write in JOIN::make_aggr_tables_info +# + +CREATE TABLE t1 ( pk int, i1 int, v1 varchar(1)); +explain +SELECT 1 FROM t1 +GROUP BY REPEAT((BINARY pk), v1), AES_DECRYPT((@A := i1), 20852) WITH ROLLUP HAVING LOAD_FILE('a') ; +SELECT 1 FROM t1 +GROUP BY REPEAT((BINARY pk), v1), AES_DECRYPT((@A := i1), 20852) WITH ROLLUP HAVING LOAD_FILE('a') ; +drop table t1; |
