LucaCappelletti94 opened a new pull request, #2854: URL: https://github.com/apache/datafusion-sqlparser-rs/pull/2854
`SELECT (VALUES (1))` read `VALUES (1)` as a call to a function named `VALUES` and printed back as `SELECT (VALUES(1))`, and `SELECT 1 = ANY (VALUES (1), (2))` failed to parse. PostgreSQL runs both as subqueries over a `VALUES` list, the reading sqlparser already gives `EXISTS (VALUES ...)` and `IN (VALUES ...)`. MySQL keeps `VALUES(col)` as a function in `ON DUPLICATE KEY UPDATE`, so the new `Dialect::supports_values_subquery_expr` decides where `VALUES` starts a subquery. It is enabled for PostgreSQL, DuckDB, SQLite and Generic, all of which execute `SELECT (VALUES (1))`. -- 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]
