clintropolis opened a new pull request, #15974:
URL: https://github.com/apache/druid/pull/15974

   ### Description
   Fixes a couple of issues with `ARRAY_CONTAINS` and `ARRAY_OVERLAP` and null 
handling. First is now if the left side is null the functions will correctly 
return null. This was also an issue in the SQL planner layer, where boolean 
typed constants were never created as null literals if the boolean expression 
was nullable, which has been fixed as well. The type inference of these 
functions now reflects that a null left side argument makes the function return 
type nullable.
   
   Finally, I think the native function evaluation should be a bit more 
efficient since it is doing contains checks with sets instead of lists, though 
I haven't measured this to be certain.
   
   <hr>
   
   This PR has:
   
   - [x] been self-reviewed.
   - [x] added comments explaining the "why" and the intent of the code 
wherever would not be obvious for an unfamiliar reader.
   - [x] added unit tests or modified existing tests to cover new code paths, 
ensuring the threshold for [code 
coverage](https://github.com/apache/druid/blob/master/dev/code-review/code-coverage.md)
 is met.
   - [x] been tested in a test Druid cluster.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to