[MDEV-23367] ROUND(18446744073709551615,-1) returns a wrong result Created: 2020-08-02  Updated: 2020-08-03  Resolved: 2020-08-03

Status: Closed
Project: MariaDB Server
Component/s: Data types
Affects Version/s: 10.1, 10.2, 10.3, 10.4, 10.5
Fix Version/s: 10.4.14, 10.5.5

Type: Bug Priority: Major
Reporter: Alexander Barkov Assignee: Alexander Barkov
Resolution: Fixed Votes: 0
Labels: None

Issue Links:
Relates
relates to MDEV-23032 FLOOR()/CEIL() incorrectly calculate ... Closed

 Description   

SELECT
  ROUND(18446744073709551615,-1),
  ROUND(18446744073709551615.0,-1);

+--------------------------------+----------------------------------+
| ROUND(18446744073709551615,-1) | ROUND(18446744073709551615.0,-1) |
+--------------------------------+----------------------------------+
|                              4 |             18446744073709551620 |
+--------------------------------+----------------------------------+


Generated at Thu Feb 08 09:21:52 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.