You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by "findingrish (via GitHub)" <gi...@apache.org> on 2024/08/08 06:13:11 UTC

Re: [PR] fix auto type column indexer realtime logical type to report long if all nulls since it is most restrictive type (druid)

findingrish commented on code in PR #16828:
URL: https://github.com/apache/druid/pull/16828#discussion_r1708709710


##########
processing/src/main/java/org/apache/druid/segment/AutoTypeColumnIndexer.java:
##########
@@ -405,8 +405,8 @@ public ColumnType getLogicalType()
       return ColumnType.NESTED_DATA;
     }
     if (isConstant && constantValue == null) {
-      // we didn't see anything, so we can be anything, so why not a string?
-      return ColumnType.STRING;
+      // we didn't see anything, so we can be anything, so be long as it is the most restrictive type
+      return ColumnType.LONG;

Review Comment:
   If this column is seen previously, should it just return that type? 



-- 
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: commits-unsubscribe@druid.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org