The materialized keyword has significant impacts on performance in real postgres databases but SQL with that in fails to parse in pg-mem
💀 Syntax error at line 4 col 13:
with bar as materialized
^
Unexpected word token: "materialized". Instead, I was expecting to see one of the following:
- A "lparen" token
To Reproduce
create table foo (x integer, y integer);
insert into foo values (1,2), (4,5);
with bar as ( select * from foo ) select * from bar;
with bar as materialized ( select * from foo ) select * from bar;
Penultimate line works fine. Adding the materialized keyword breaks it.
pg-mem version
2.8.1 (also fails in playground at time of writing)
Describe the bug
Common Table Expressions (CTEs) or "with" blocks are supported by postgres and pg-mem. See https://www.postgresql.org/docs/current/queries-with.html for background
The materialized keyword has significant impacts on performance in real postgres databases but SQL with that in fails to parse in pg-mem
To Reproduce
Penultimate line works fine. Adding the materialized keyword breaks it.
pg-mem version
2.8.1 (also fails in playground at time of writing)