You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
presto returns a NaN, even if there is a NULL in the array. However, for other types, it always returns NULL if one exists. As a part of fixing the NaN behavior under this RFC (https://github.com/prestodb/rfcs/blob/main/RFC-0001-nan-definition.md), it would be good to also make the behavior consistent across types for nulls and always return null if it exists.
elharo
changed the title
Inconsistent Null handling in array_max/min functions
Inconsistent Null handling in array_max/min functions in presence of NaN
May 16, 2024
NaN's a weird one. I'm not sure we should do this. I'm not sure we shouldn't. However, I do notice that the RFC doesn't address the case of null comparisons with NaN and whichever way we go it likely should.
presto returns a NaN, even if there is a NULL in the array. However, for other types, it always returns NULL if one exists. As a part of fixing the NaN behavior under this RFC (https://github.com/prestodb/rfcs/blob/main/RFC-0001-nan-definition.md), it would be good to also make the behavior consistent across types for nulls and always return null if it exists.
Similarly for array_max
The text was updated successfully, but these errors were encountered: