summaryrefslogtreecommitdiff
path: root/mysql-test/t
diff options
context:
space:
mode:
authorunknown <konstantin@mysql.com>2003-12-10 15:17:23 +0300
committerunknown <konstantin@mysql.com>2003-12-10 15:17:23 +0300
commit02f56e77e0f71197679ea8784f07be98fb17ce27 (patch)
tree641c98843d10a709fe921109ede6b392646dad8d /mysql-test/t
parent0cc52bc7ca3718215a414c8e8df44e0af43dab9a (diff)
downloadmariadb-git-02f56e77e0f71197679ea8784f07be98fb17ce27.tar.gz
followup to fix for bug #1790 BIT_AND() result in GROUP BY different when
SQL_BIG_RESULT used": now BIT_AND() always returns 18446744073709551615 if no rows were found. This patch also fixes bug #1972: "BIT_AND() and BIT_OR() still return a *signed* 64bit value" mysql-test/r/func_group.result: followup to fix for bug #1790 BIT_AND() result in GROUP BY different when SQL_BIG_RESULT used": test results fixed bug #1972 "BIT_AND() and BIT_OR() still return a *signed* 64bit value": results of new tests mysql-test/t/func_group.test: added tests for bug #1972 "BIT_AND() and BIT_OR() still return a *signed* 64bit value"
Diffstat (limited to 'mysql-test/t')
-rw-r--r--mysql-test/t/func_group.test8
1 files changed, 8 insertions, 0 deletions
diff --git a/mysql-test/t/func_group.test b/mysql-test/t/func_group.test
index 40d829d3e70..d03e4b9b629 100644
--- a/mysql-test/t/func_group.test
+++ b/mysql-test/t/func_group.test
@@ -147,3 +147,11 @@ insert into t1 values (3,1);
select a,count(b), sum(b), avg(b), std(b), min(b), max(b), bit_and(b), bit_or(b) from t1 group by a;
select SQL_BIG_RESULT a,count(b), sum(b), avg(b), std(b), min(b), max(b), bit_and(b), bit_or(b) from t1 group by a;
drop table t1;
+#
+# Bug #1972: test for bit_and(), bit_or() and negative values
+#
+create table t1 (col int);
+insert into t1 values (-1), (-2), (-3);
+select bit_and(col), bit_or(col) from t1;
+select SQL_BIG_RESULT bit_and(col), bit_or(col) from t1 group by col;
+drop table t1;