1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Post-review fixes for bug #20924

mysql-test/r/case.result:
  Post-review fix for bug #20924
mysql-test/r/func_if.result:
  Post-review fix for bug #20924
mysql-test/r/func_test.result:
  Post-review fix for bug #20924
mysql-test/r/user_var.result:
  Post-review fix for bug #20924
mysql-test/t/case.test:
  Post-review fix for bug #20924
mysql-test/t/func_if.test:
  Post-review fix for bug #20924
mysql-test/t/func_test.test:
  Post-review fix for bug #20924
mysql-test/t/user_var.test:
  Post-review fix for bug #20924
sql/item_func.cc:
  Post-review fix for bug #20924
sql/item_func.h:
  Post-review fix for bug #20924
sql/log_event.cc:
  Post-review fix for bug #20924
This commit is contained in:
unknown
2006-09-12 16:25:40 +04:00
parent f64483cb90
commit 5aa6e8615e
11 changed files with 31 additions and 18 deletions

View File

@ -183,3 +183,4 @@ CASE 1 WHEN 1 THEN 18446744073709551615 ELSE 1 END
SELECT COALESCE(18446744073709551615);
COALESCE(18446744073709551615)
18446744073709551615
End of 4.1 tests

View File

@ -105,3 +105,4 @@ IF(1 != 0, 18446744073709551615, 1)
SELECT IFNULL(NULL, 18446744073709551615);
IFNULL(NULL, 18446744073709551615)
18446744073709551615
End of 4.1 tests

View File

@ -189,3 +189,4 @@ GREATEST(1, 18446744073709551615)
SELECT LEAST(1, 18446744073709551615);
LEAST(1, 18446744073709551615)
1
End of 4.1 tests

View File

@ -207,3 +207,4 @@ set @a=18446744073709551615;
select @a;
@a
18446744073709551615
End of 4.1 tests

View File

@ -131,9 +131,11 @@ from t1 where b=3 group by b;
drop table t1;
#
# Bug #20924: UNSIGNED values in CASE and COALESCE are treated as SIGNED
# Bug #20924: CAST(expr as UNSIGNED) returns SIGNED value when used in various
# functions
# - UNSIGNED values in CASE and COALESCE are treated as SIGNED
#
SELECT CASE 1 WHEN 1 THEN 18446744073709551615 ELSE 1 END;
SELECT COALESCE(18446744073709551615);
# End of 4.1 tests
--echo End of 4.1 tests

View File

@ -74,13 +74,17 @@ SELECT a, NULLIF(a,'') FROM t1 WHERE NULLIF(a,'') IS NULL;
DROP TABLE t1;
#
# Bug #20924: UNSIGNED values in IF() are treated as SIGNED
# Bug #20924: CAST(expr as UNSIGNED) returns SIGNED value when used in various
# functions
# - UNSIGNED values in IF() are treated as SIGNED
#
SELECT IF(1 != 0, 18446744073709551615, 1);
#
# Bug #20924: UNSIGNED values in IFNULL() are treated as SIGNED
# Bug #20924: CAST(expr as UNSIGNED) returns SIGNED value when used in various
# functions
# - UNSIGNED values in IFNULL() are treated as SIGNED
#
SELECT IFNULL(NULL, 18446744073709551615);
# End of 4.1 tests
--echo End of 4.1 tests

View File

@ -109,9 +109,11 @@ select 5.1 mod 3, 5.1 mod -3, -5.1 mod 3, -5.1 mod -3;
select 5 mod 3, 5 mod -3, -5 mod 3, -5 mod -3;
#
# Bug #20924: UNSIGNED values in GREATEST() and LEAST() are treated as SIGNED
# Bug #20924: CAST(expr as UNSIGNED) returns SIGNED value when used in various
# functions
# - UNSIGNED values in GREATEST() and LEAST() are treated as SIGNED
#
SELECT GREATEST(1, 18446744073709551615);
SELECT LEAST(1, 18446744073709551615);
# End of 4.1 tests
--echo End of 4.1 tests

View File

@ -142,9 +142,11 @@ select @@global.version;
select @@session.VERSION;
#
# Bug #20924 SET on a user variable saves UNSIGNED as SIGNED
# Bug #20924: CAST(expr as UNSIGNED) returns SIGNED value when used in various
# functions
# - SET on a user variable saves UNSIGNED as SIGNED
#
set @a=18446744073709551615;
select @a;
# End of 4.1 tests
--echo End of 4.1 tests