KKcorps commented on code in PR #10386:
URL: https://github.com/apache/pinot/pull/10386#discussion_r1150189424
##########
pinot-core/src/main/java/org/apache/pinot/core/operator/transform/function/BaseTransformFunction.java:
##########
@@ -188,6 +259,57 @@ public long[] transformToLongValuesSV(ValueBlock
valueBlock) {
return _longValuesSV;
}
+ @Override
+ public Pair<long[], RoaringBitmap>
transformToLongValuesSVWithNull(ValueBlock valueBlock) {
+ int length = valueBlock.getNumDocs();
+ if (_longValuesSV == null) {
+ _longValuesSV = new long[length];
+ }
+ RoaringBitmap bitmap;
+ DataType resultDataType = getResultMetadata().getDataType();
+ switch (resultDataType.getStoredType()) {
+ case UNKNOWN:
+ bitmap = new RoaringBitmap();
+ bitmap.add(0L, length);
+ for (int i = 0; i < length; i++) {
+ _longValuesSV[i] = (long)
DataSchema.ColumnDataType.LONG.getNullPlaceholder();
Review Comment:
what's the need to do copy when all bits are set to 0 in bitmap?
Is it to show some placeholder value in the end?
--
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]