SQL Impala convert NaN values to NULL values

Viewed 75

I have the following column in my table:

col 1
1
3
NULL
NaN
5

"Bad" aggregations return NaN instead of NULL and the variable is type DOUBLE in the end. I want to have one type of missing values only, hence I need to convert NULL to NaN or the other way around. My problem is that when I partition with a window function it does not recognize NaNs as equal to NULLS and creates separate subgroups, which is something I do not want. Any suggestions on how to convert them?

0 Answers
Related