diff options
Diffstat (limited to 'mysql-test')
-rw-r--r-- | mysql-test/r/win.result | 16 | ||||
-rw-r--r-- | mysql-test/t/win.test | 17 |
2 files changed, 32 insertions, 1 deletions
diff --git a/mysql-test/r/win.result b/mysql-test/r/win.result index c6707bd51bc..9b4ebe60997 100644 --- a/mysql-test/r/win.result +++ b/mysql-test/r/win.result @@ -3173,3 +3173,19 @@ Nth_value(i,1) OVER() 1 1 DROP TABLE t1; +# +# MDEV-13355: Assertion `using_unique_constraint || group_buff <= param->group_buff + +# param->group_length' failed in create_tmp_table +# +CREATE TABLE t1 (i INT); +INSERT INTO t1 VALUES (1),(2); +SELECT * FROM ( +SELECT +ROW_NUMBER() OVER(), i +FROM t1 +WHERE 1=0 +GROUP BY i +) AS sq +; +ROW_NUMBER() OVER() i +DROP TABLE t1; diff --git a/mysql-test/t/win.test b/mysql-test/t/win.test index 77ca755378d..9de4fd66fc5 100644 --- a/mysql-test/t/win.test +++ b/mysql-test/t/win.test @@ -1953,4 +1953,19 @@ UNION ALL ( SELECT Nth_value(i,2) OVER() FROM t1 LIMIT 0 ) ; DROP TABLE t1; - +--echo # +--echo # MDEV-13355: Assertion `using_unique_constraint || group_buff <= param->group_buff + +--echo # param->group_length' failed in create_tmp_table +--echo # +CREATE TABLE t1 (i INT); +INSERT INTO t1 VALUES (1),(2); + +SELECT * FROM ( + SELECT + ROW_NUMBER() OVER(), i + FROM t1 + WHERE 1=0 + GROUP BY i +) AS sq +; +DROP TABLE t1; |