abhishekrb19 opened a new issue, #12856:
URL: https://github.com/apache/druid/issues/12856

   SQL queries don't return rows with null values when null and non-null 
predicates over a dimension are specified in the where clause. For example, the 
following query only returns rows with `X = 0`:
   
   ```sql
   SELECT X, __time
   FROM my_data
   WHERE (X IS NULL OR X = 0) 
   ```
   
   However, if I remove the `X = 0` predicate, Druid _does_ return rows with 
null as expected.  Combining null and non-null predicates over the same 
dimension seems to be the issue.
   
   Further looking into the query plan, I see this:
   ```json
      {
           "type": "in",
           "dimension": "X",
           "values": [
             null,
             "0"
           ]
         } 
   ```
   I think `null` values aren't compatible with `in` and should be treated 
differently?
   
   This issue is found in Druid 0.20.1.
   
   /cc: @clintropolis 


-- 
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