[ 
https://issues.apache.org/jira/browse/FLINK-10049?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16811903#comment-16811903
 ] 

LiuJi edited comment on FLINK-10049 at 4/7/19 2:53 PM:
-------------------------------------------------------

It seems string functions in different SQL engines may have different behaviors 
with NULL value. for example, as you mentioned above, LOG10(NULL) throws NPE, 
but in other SQL engine it could return null. The same applies to ABS, it may 
throw Exception with NULL param. I'm not sure if there is a grammatical 
standard in string functions? [~xccui]


was (Author: tianchen92):
It seems string functions in different SQL engines may have different behaviors 
with NULL value. for example, as you mentioned above, LOG10(NULL) throws NPE, 
but in other SQL engine it will return null. The same applies to ABS, it may 
throw Exception with NULL param. I'm not sure if there is a grammatical 
standard in string functions? [~xccui]

> Unify the processing logic for NULL arguments in SQL built-in functions
> -----------------------------------------------------------------------
>
>                 Key: FLINK-10049
>                 URL: https://issues.apache.org/jira/browse/FLINK-10049
>             Project: Flink
>          Issue Type: Improvement
>          Components: Table SQL / API
>            Reporter: Xingcan Cui
>            Priority: Major
>
> Currently, the built-in functions treat NULL arguments in different ways. 
> E.g., ABS(NULL) returns NULL, while LOG10(NULL) throws an NPE. The general 
> SQL-way of handling NULL values should be that if one argument is NULL the 
> result is NULL. We should unify the processing logic for that.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to