You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "jaylmiller (via GitHub)" <gi...@apache.org> on 2023/02/24 18:11:25 UTC

[GitHub] [arrow-datafusion] jaylmiller commented on a diff in pull request #5380: UDF zero params #5378

jaylmiller commented on code in PR #5380:
URL: https://github.com/apache/arrow-datafusion/pull/5380#discussion_r1117431902


##########
datafusion/physical-expr/src/planner.rs:
##########
@@ -393,7 +393,10 @@ pub fn create_physical_expr(
                     execution_props,
                 )?);
             }
-
+            // udfs with zero params expect null array as input
+            if args.is_empty() {
+                physical_args.push(Arc::new(Literal::new(ScalarValue::Null)));

Review Comment:
   Sounds good. Thanks for the suggestions!



-- 
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: github-unsubscribe@arrow.apache.org

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