You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Parse WITH ... AS [NOT] MATERIALIZED in GenericDialect, DuckDbDialect and SQLiteDialect #2622
DataFusion is adding support for the directive in apache/datafusion#25580 (issue apache/datafusion#17737). The default dialect of DataFusion is GenericDialect, so users must change the dialect to PostgreSQL to use it.
DuckDB and SQLite accept the same syntax in the same position, so DuckDbDialect and SQLiteDialect should also parse it.
Proposal
Replace the dialect_of! check with a dialect method, for example Dialect::supports_cte_materialized(), that returns true for PostgreSqlDialect, GenericDialect, DuckDbDialect and SQLiteDialect.
MATERIALIZED directly after AS and before ( is not ambiguous with other syntax, so the change is small.
Activity
Upgrade vendored sqlparser to v0.63.0 (#4278)
Upgrade vendored sqlparser to main-dacdbc99cd16 (#4761)
feat: support `WITH ... AS [NOT] MATERIALIZED` CTEs (apache#25580)
feat: support `WITH ... AS [NOT] MATERIALIZED` CTEs (apache#25580)
feat: support `WITH ... AS [NOT] MATERIALIZED` CTEs (apache#25580)
LAV-5387: Upgrade vendored sqlparser to main-d32825d6f9c6 (#5248)