summaryrefslogtreecommitdiff
path: root/mysql-test/t/select_found.test
diff options
context:
space:
mode:
authorunknown <igor@rurik.mysql.com>2005-01-22 02:42:54 -0800
committerunknown <igor@rurik.mysql.com>2005-01-22 02:42:54 -0800
commitd3db70de4c6027b9ae62b0814cdd45718e58a556 (patch)
tree8af432a50c14f0944f9bc73bab399c79cfce652f /mysql-test/t/select_found.test
parentc695ccd27e753fe9ed67dc28443de7639203a4bc (diff)
parent25c2d1adb09a3dd521a110013ab03eac3e1fc01a (diff)
downloadmariadb-git-d3db70de4c6027b9ae62b0814cdd45718e58a556.tar.gz
Merge rurik.mysql.com:/home/igor/dev/mysql-4.0-0
into rurik.mysql.com:/home/igor/dev/mysql-4.1-0 mysql-test/r/select_found.result: Auto merged mysql-test/t/select_found.test: Auto merged sql/sql_select.cc: Auto merged
Diffstat (limited to 'mysql-test/t/select_found.test')
-rw-r--r--mysql-test/t/select_found.test9
1 files changed, 9 insertions, 0 deletions
diff --git a/mysql-test/t/select_found.test b/mysql-test/t/select_found.test
index 943174462e3..d31d7d0b02e 100644
--- a/mysql-test/t/select_found.test
+++ b/mysql-test/t/select_found.test
@@ -166,3 +166,12 @@ INSERT INTO t1 VALUES (0), (0), (1), (2);
SELECT SQL_CALC_FOUND_ROWS * FROM t1 WHERE a = 0 GROUP BY a HAVING a > 10;
SELECT FOUND_ROWS();
DROP TABLE t1;
+
+#
+# Bug #7945: group by + distinct with constant expression + limit
+#
+
+CREATE TABLE t1 (a int, b int);
+INSERT INTO t1 VALUES (1,2), (1,3), (1,4), (1,5);
+SELECT SQL_CALC_FOUND_ROWS DISTINCT 'a' FROM t1 GROUP BY b LIMIT 2;
+SELECT FOUND_ROWS();