findepi opened a new issue, #16516: URL: https://github.com/apache/datafusion/issues/16516
### Is your feature request related to a problem or challenge? ``` $ cargo run --bin datafusion-cli Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.18s Running `target/debug/datafusion-cli` DataFusion CLI v48.0.0 > SELECT array_agg(a_varchar) filter (where a_varchar is not null) FROM (VALUES ('a'), ('d'), ('c'), ('a')) t(a_varchar); 🤔 Invalid statement: SQL error: ParserError("Expected: end of statement, found: ( at Line: 1, Column: 36") ``` ### Describe the solution you'd like This is standard syntax and supported under PostgreSQL dialect `set datafusion.sql_parser.dialect = 'Postgres';` is enabled. Add support for filtered aggregations in the default dialect (Generic) as well. ### Describe alternatives you've considered Using Postgres dialect. I should not be forced out of my preferred dialect to access an existing feature, unless that feature is truly dialect-specific. Moreover, switching to PostgreSQL dialect has its own issues: https://github.com/apache/datafusion/issues/16515 ### Additional context _No response_ -- 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.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