[MDEV-4714] Wrong TIME value from a long string Created: 2013-06-26  Updated: 2022-09-08

Status: Open
Project: MariaDB Server
Component/s: None
Affects Version/s: 10.0.3, 5.5.31, 5.1.67, 5.2.14, 5.3.12
Fix Version/s: 5.5

Type: Bug Priority: Minor
Reporter: Alexander Barkov Assignee: Alexander Barkov
Resolution: Unresolved Votes: 0
Labels: None


 Description   

This query

mysql> select time('11111112233');
+---------------------+
| time('11111112233') |
+---------------------+
| 838:59:59.999999    |
+---------------------+
1 row in set, 1 warning (0.00 sec)

correctly adjusts (with a warning) the results to the maximum supported
value. However, if the string gets longer, it does not work any more:

mysql> select time('111111112233');
+----------------------+
| time('111111112233') |
+----------------------+
| 11:22:33             |
+----------------------+

The last query should be fixed to adjust the TIME value and produce a warning.


Generated at Thu Feb 08 06:58:35 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.