You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "KKcorps (via GitHub)" <gi...@apache.org> on 2023/04/12 05:36:22 UTC

[GitHub] [pinot] KKcorps commented on a diff in pull request #10563: [feature] [null support # 6] Use default null support for array transform functions

KKcorps commented on code in PR #10563:
URL: https://github.com/apache/pinot/pull/10563#discussion_r1163636788


##########
pinot-core/src/test/java/org/apache/pinot/core/operator/transform/function/ArrayBaseTransformFunctionTest.java:
##########
@@ -76,6 +78,101 @@ public void testArrayTransformFunction() {
     }
   }
 
+  @Test
+  public void testArrayNullColumn() {
+    ExpressionContext expression =
+        RequestContextUtils.getExpression(String.format("%s(%s)", getFunctionName(), INT_MV_NULL_COLUMN));
+    TransformFunction transformFunction = TransformFunctionFactory.get(expression, _dataSourceMap);
+    Assert.assertEquals(transformFunction.getClass().getName(), getArrayFunctionClass().getName());
+    Assert.assertEquals(transformFunction.getName(), getFunctionName());
+    Assert.assertEquals(transformFunction.getResultMetadata().getDataType(), getResultDataType(FieldSpec.DataType.INT));
+    Assert.assertTrue(transformFunction.getResultMetadata().isSingleValue());
+    Assert.assertFalse(transformFunction.getResultMetadata().hasDictionary());
+
+    switch (getResultDataType(FieldSpec.DataType.INT)) {
+      case INT:
+        Pair<int[], RoaringBitmap> intResults = transformFunction.transformToIntValuesSVWithNull(_projectionBlock);

Review Comment:
   Why is `SVWithNull` being called here? Shouldn't it be`MVWithNull`



-- 
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@pinot.apache.org

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


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