alamb commented on issue #17379: URL: https://github.com/apache/datafusion/issues/17379#issuecomment-3254247177
> I am not confident if we support anything other than literal values for the expressions we pass via Table Functions. It seems like nothing else makes a lot of sense, but I don't have enough use cases to support this. If we do only stick with literal values, then I think this could be done with a non-breaking change where we pass the name of the named expression as metadata on the literal value. I think we only support passing ScalarValues (or expressions passed to scalar values) to [table functions](https://datafusion.apache.org/library-user-guide/functions/adding-udfs.html#adding-a-user-defined-table-). However, this just came up at Influx so I'll try and file a ticket to support actual table parameters to user defined tables too In terms of supporting the postgresql syntax ``` SELECT concat_lower_or_upper(a => 'Hello', b => 'World'); ``` Perhaps we could pass the names of the arguments via the names of `fields` in `ScalarFunctionArgs` https://docs.rs/datafusion/latest/datafusion/logical_expr/struct.ScalarFunctionArgs.html I think the trick would be how to update [ScalarUdfImpl::signature](https://docs.rs/datafusion/latest/datafusion/logical_expr/trait.ScalarUDFImpl.html#tymethod.signature) to contain the names too. -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
