generated from amazon-archives/__template_Custom
-
Notifications
You must be signed in to change notification settings - Fork 179
Closed
Labels
PPLPiped processing languagePiped processing languageSQLbi-toolingbugSomething isn't workingSomething isn't workingdata-correctness
Description
What is the bug?
ROUND, FLOOR and CEILING functions don't work well with values > INT_MAX or < -INT_MAX
How can one reproduce the bug?
opensearchsql> select ROUND(9223372036854775807), FLOOR(9223372036854775807), CEILING(9223372036854775807);
fetched rows / total rows = 1/1
+------------------------------+------------------------------+--------------------------------+
| ROUND(9223372036854775807) | FLOOR(9223372036854775807) | CEILING(9223372036854775807) |
|------------------------------+------------------------------+--------------------------------|
| 2147483647 | 2147483647 | 2147483647 |
+------------------------------+------------------------------+--------------------------------+9223372036854775807 == LONG_MAX
Those functions return INTEGER instead of LONG.
What is the expected behavior?
Functions should return LONG.
What is your host/environment?
2.x @ 21373b9
Do you have any additional context?
Reported on behalf of @kylepbit
Metadata
Metadata
Assignees
Labels
PPLPiped processing languagePiped processing languageSQLbi-toolingbugSomething isn't workingSomething isn't workingdata-correctness