gstvg commented on code in PR #1686:
URL:
https://github.com/apache/datafusion-sqlparser-rs/pull/1686#discussion_r1935916968
##########
src/dialect/mod.rs:
##########
@@ -340,12 +340,21 @@ pub trait Dialect: Debug + Any {
/// Returns true if the dialect supports lambda functions, for example:
///
/// ```sql
- /// SELECT transform(array(1, 2, 3), x -> x + 1); -- returns [2,3,4]
+ /// SELECT transform(array(1, 2, 3), (x) -> x + 1); -- returns [2,3,4]
/// ```
fn supports_lambda_functions(&self) -> bool {
false
}
+ /// Returns true if the dialect supports lambda functions without
parentheses for a single argument, for example:
+ ///
+ /// ```sql
+ /// SELECT transform(array(1, 2, 3), x -> x + 1); -- returns [2,3,4]
+ /// ```
+ fn supports_parensless_lambda_functions(&self) -> bool {
Review Comment:
Agreed. `supports_parensless_lambda_functions` is removed and lambda support
restricted to clickhouse, databricks and duckdb. I actually forgot the nested
expr `(expr)`, so yes, this conflicted with pg, it just wasn't caught by any
test, plain wrong. Thanks :pray:
--
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]