clintropolis commented on code in PR #13653:
URL: https://github.com/apache/druid/pull/13653#discussion_r1066574575


##########
processing/src/main/java/org/apache/druid/segment/NestedDataColumnIndexer.java:
##########
@@ -151,7 +177,79 @@ public ColumnValueSelector<?> makeColumnValueSelector(
       IncrementalIndex.DimensionDesc desc
   )
   {
-    final int dimIndex = desc.getIndex();
+
+    if (fieldIndexers.size() == 1 && 
fieldIndexers.containsKey(NestedPathFinder.JSON_PATH_ROOT)) {
+      final LiteralFieldIndexer rootField = 
fieldIndexers.get(NestedPathFinder.JSON_PATH_ROOT);
+      if (rootField.getTypes().getSingleType() != null) {
+        return new ColumnValueSelector<Object>()
+        {
+          @Override
+          public boolean isNull()
+          {
+            final Object o = getObject();
+            return !(o instanceof Number);

Review Comment:
   `isNull` is technically from javadocs: ```Returns true if the primitive 
long, double, or float value returned by this selector should be treated as 
null.``` so in this case its treating anything that is not numeric as null 
since it is going to precede a call to `getLong`/`getDouble`/`getFloat`



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