Jimexist opened a new issue #305:
URL: https://github.com/apache/arrow-datafusion/issues/305


   **Is your feature request related to a problem or challenge? Please describe 
what you are trying to do.**
   
   A challenge to allow `ScalarFunctionImplementation` to take more than just 
the `vec` of `columnar` values, because in case of no-arg functions like 
`random()`, there's no way to tell the desired output array length.
   
   **Describe the solution you'd like**
   A clear and concise description of what you want to happen.
   
   change
   
   ```rust
   /// Scalar function
   pub type ScalarFunctionImplementation =
       Arc<dyn Fn(ScalarFunctionArgs) -> Result<ColumnarValue> + Send + Sync>;
   ```
   
   to something like
   
   ```rust
   /// Scalar function
   pub type ScalarFunctionImplementation =
       Arc<dyn Fn(ScalarFunctionArgs) -> Result<ColumnarValue> + Send + Sync>;
   ```
   
   ```rust
   /// Scalar function
   pub type ScalarFunctionImplementation =
       Arc<dyn Fn(usize, ScalarFunctionArgs) -> Result<ColumnarValue> + Send + 
Sync>;
   ```
   
   where the first param `usize` is the batch size
   
   **Describe alternatives you've considered**
   A clear and concise description of any alternative solutions or features 
you've considered.
   
   **Additional context**
   Add any other context or screenshots about the feature request here.
   


-- 
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.

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


Reply via email to