summaryrefslogtreecommitdiff
path: root/mysql-test/r
diff options
context:
space:
mode:
authorAlexey Kopytov <Alexey.Kopytov@Sun.com>2009-09-08 12:36:40 +0400
committerAlexey Kopytov <Alexey.Kopytov@Sun.com>2009-09-08 12:36:40 +0400
commit0a7e41864c95cbdec512cc9f1078ace09528d0b7 (patch)
tree2e5b497125e21da04a070286b94d038c59177230 /mysql-test/r
parentfe3b6356ca924b2d1313417bcf5a302f0ba70869 (diff)
parent505346028f975d26f1353c46bdb3db618b1e306c (diff)
downloadmariadb-git-0a7e41864c95cbdec512cc9f1078ace09528d0b7.tar.gz
Automerge.
Diffstat (limited to 'mysql-test/r')
-rw-r--r--mysql-test/r/distinct.result30
1 files changed, 30 insertions, 0 deletions
diff --git a/mysql-test/r/distinct.result b/mysql-test/r/distinct.result
index e0324af8cfd..b1cb70fa43c 100644
--- a/mysql-test/r/distinct.result
+++ b/mysql-test/r/distinct.result
@@ -763,4 +763,34 @@ a b d c
1 2 0 2
1 2 0 3
DROP TABLE t1;
+#
+# Bug #46159: simple query that never returns
+#
+SET @old_max_heap_table_size = @@max_heap_table_size;
+SET @@max_heap_table_size = 16384;
+SET @old_sort_buffer_size = @@sort_buffer_size;
+SET @@sort_buffer_size = 32804;
+CREATE TABLE t1(c1 int, c2 VARCHAR(20));
+INSERT INTO t1 VALUES (1, '1'), (1, '1'), (2, '2'), (3, '1'), (3, '1'), (4, '4');
+INSERT INTO t1 SELECT 5 + 10000 * RAND(), '5' FROM t1;
+INSERT INTO t1 SELECT 5 + 10000 * RAND(), '5' FROM t1;
+INSERT INTO t1 SELECT 5 + 10000 * RAND(), '5' FROM t1;
+INSERT INTO t1 SELECT 5 + 10000 * RAND(), '5' FROM t1;
+INSERT INTO t1 SELECT 5 + 10000 * RAND(), '5' FROM t1;
+INSERT INTO t1 SELECT 5 + 10000 * RAND(), '5' FROM t1;
+INSERT INTO t1 SELECT 5 + 10000 * RAND(), '5' FROM t1;
+INSERT INTO t1 SELECT 5 + 10000 * RAND(), '5' FROM t1;
+SELECT c1, c2, COUNT(*) FROM t1 GROUP BY c1 LIMIT 4;
+c1 c2 COUNT(*)
+1 1 2
+2 2 1
+3 1 2
+4 4 1
+SELECT DISTINCT c2 FROM t1 GROUP BY c1 HAVING COUNT(*) > 1;
+c2
+1
+5
+DROP TABLE t1;
+SET @@sort_buffer_size = @old_sort_buffer_size;
+SET @@max_heap_table_size = @old_max_heap_table_size;
End of 5.1 tests