Re: Early WIP/PoC for inlining CTEs
От | Andreas Karlsson |
---|---|
Тема | Re: Early WIP/PoC for inlining CTEs |
Дата | |
Msg-id | 00818be9-2f63-f584-efcd-d97ee0662905@proxel.se обсуждение исходный текст |
Ответ на | Re: Early WIP/PoC for inlining CTEs (Robert Haas <robertmhaas@gmail.com>) |
Ответы |
Re: Early WIP/PoC for inlining CTEs
Re: Early WIP/PoC for inlining CTEs |
Список | pgsql-hackers |
On 1/11/19 8:10 PM, Robert Haas wrote: > WITH cte_name [[NOT] MATERIALIZED] AS (query) main_query... Hm, when would one want "NOT MATERIALIZED"? I am not sure I see the usefulness of forcing inlining other than if we by default do not inline when a CTE is referenced multiple times. Do you imaging it working something like the below? 1. Default # Not inlined - Referenced multiple times - Includes FOR UPDATE|SHARE - Includes volatile functions - Recurisve - DML # Inlined - Simple case (no side effects, referenced once) 2. MATERIALIZED # Not inlined - Everything # Inlined - (none) 3. NOT MATERIALIZED # Not inlined - Recursive - DML # Inlined - Everything else Andreas
В списке pgsql-hackers по дате отправления: