alamb commented on issue #13552:
URL: https://github.com/apache/datafusion/issues/13552#issuecomment-2499058829

   > String functions MUST accept scalar values for all config arguments but 
MAY accept both scalar and array if appropriate for the function.
   
   is a "config" argument well defined (I assume it means something like 
`concat_ws(column, '**')` where the function mostly follows
   
   > String functions SHOULD rely on type coercion to handle non-string data. 
For example, concat('ab', 2, 'cc').
   
   This makes sense to me. I also did a little digging and found this:
   
   
https://github.com/apache/datafusion/blob/7553b3b5edeb45dfda891b3646e3b7ea3e07e790/datafusion/expr-common/src/signature.rs#L141-L145
   
   So maybe best  practice would be that string functions used the 
`Signature::String` or equivalent coercion rules 
   
   > String functions MAY choose to allow non-contiguous data types for data 
arguments but it is NOT RECOMMENDED for functions with 3 or more arguments.
   
   
   It might make sense to define what "non-contiguous" means in this context 
(does it mean having special implementations when there are multiple input 
arguments that are not exactly the same type -- e.g. Utf8View and Utf8)?
   


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