Bug #119586 Inconsistent results for date conversion
Submitted: 23 Dec 9:09 Modified: 26 Dec 16:49
Reporter: John Jove Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Data Types Severity:S1 (Critical)
Version:8.4.7 OS:Any
Assigned to: CPU Architecture:Any

[23 Dec 9:09] John Jove
Description:
Run the following two cases, which are expected to return the same result.

How to repeat:
DROP TABLE t1;
CREATE TABLE t1 (c1 SMALLINT);
INSERT INTO t1 VALUES(1);
SELECT nullif(date(0), c1) FROM t1; -- {NULL}

DROP TABLE t1;
CREATE TABLE t1 (c1 BIGINT UNSIGNED);
INSERT INTO t1 VALUES(1);
SELECT nullif(date(0), c1) FROM t1; -- {0}
[26 Dec 16:49] Roy Lyseng
Verified as described.