OSDir


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GitHub] jihoonson commented on a change in pull request #5958: Part 2 of changes for SQL Compatible Null Handling


jihoonson commented on a change in pull request #5958: Part 2 of changes for SQL Compatible Null Handling
URL: https://github.com/apache/incubator-druid/pull/5958#discussion_r201192194
 
 

 ##########
 File path: extensions-core/histogram/src/main/java/io/druid/query/aggregation/histogram/ApproximateHistogramAggregator.java
 ##########
 @@ -59,7 +60,9 @@ public ApproximateHistogramAggregator(
   @Override
   public void aggregate()
   {
-    histogram.offer(selector.getFloat());
+    if (NullHandling.replaceWithDefault() || !selector.isNull()) {
 
 Review comment:
   What does `NullHandling.replaceWithDefault()` mean here? Does that mean nulls have replaced with some default value at ingestion time? If so, I guess `select.isNull()` always return `false` and thus this check can be simplified into `if (!selector.isNull())`.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@xxxxxxxxxxxxxxxx


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: dev-help@xxxxxxxxxxxxxxxx