Bug #68864 | INTERVAL treats null values of text columns as float/int | ||
---|---|---|---|
Submitted: | 4 Apr 2013 8:17 | Modified: | 4 Apr 2013 8:37 |
Reporter: | Jaik Dean | Email Updates: | |
Status: | Verified | Impact on me: | |
Category: | MySQL Server: Data Types | Severity: | S2 (Serious) |
Version: | 5.6.10 | OS: | Any |
Assigned to: | CPU Architecture: | Any | |
Tags: | FLOAT, interval, null |
[4 Apr 2013 8:17]
Jaik Dean
[4 Apr 2013 8:37]
MySQL Verification Team
results for 5.0, 5.1, 5.5: -------------------------- mysql> select date_add('2013-04-03 12:00:00', interval null second) as `duration`; +----------+ | duration | +----------+ | NULL | +----------+ 1 row in set (0.00 sec) mysql> select date_add('2013-04-03 12:00:00', interval `a`.`data` second) as `duration` from `a`; +----------+ | duration | +----------+ | NULL | +----------+ 1 row in set (0.00 sec) Results for 5.6, 5.7: ---------------------- mysql> select date_add('2013-04-03 12:00:00', interval null second) as `duration`; +----------+ | duration | +----------+ | NULL | +----------+ 1 row in set (0.00 sec) mysql> select date_add('2013-04-03 12:00:00', interval `a`.`data` second) as `duration` from `a`; +---------------------+ | duration | +---------------------+ | 2013-04-03 12:00:00 | +---------------------+ 1 row in set (0.00 sec)