jayzhan211 commented on issue #10424:
URL: https://github.com/apache/datafusion/issues/10424#issuecomment-2103912260

   > Is it possible to make the `array_slice` function accept a vector as its 
parameter?
   > 
   > ```rust
   > fn array_slice(args: Vec<Expr>) {
   > }
   > ```
   > 
   > When making its UDF function, we need to do
   > 
   > ```rust
   > make_udf_function!(
   >     ArraySlice,
   >     array_slice,
   >     "returns a slice of the array.",
   >     array_slice_udf
   > );
   > ```
   
   The downside of this is we loss the clear argument name and we need to check 
args length.
   
   > fn array_slice_with_stride(array:Expr, begin:Expr, end:Expr, stride:Expr) {
   ...
   }
   
   I prefer this


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

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


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to