-
Notifications
You must be signed in to change notification settings - Fork 25.7k
Open
Labels
:Analytics/SQLSQL queryingSQL querying>bugTeam:AnalyticsMeta label for analytical engine team (ESQL/Aggs/Geo)Meta label for analytical engine team (ESQL/Aggs/Geo)
Description
The following SQL query:
SELECT ROUND('NaN'::double)
results in:
ROUND('NaN'::double)
--------------------
-0.0
Other major relational DBs behave differently.
MySQL and MSSQL does not have NaN (only NULL ), ROUND(NULL) is NULL.
PostgreSQL and Oracle has NaN and ROUND(NaN) returns NaN.
Was it intentional that we kept this in-sync with the Math.round() behaviour and different from the relational DBs above?
Note: H2 (that we check against in integration tests) also follows the behaviour of Math.round().
Metadata
Metadata
Assignees
Labels
:Analytics/SQLSQL queryingSQL querying>bugTeam:AnalyticsMeta label for analytical engine team (ESQL/Aggs/Geo)Meta label for analytical engine team (ESQL/Aggs/Geo)