3 ms·
> and it has no way to serialize a query plan to some form that can be shared between processes https://www.postgresql.org/docs/current/parallel-query.html htt
by hans_castorp 7mo ago
> and it has no way to serialize a query plan to some form that can be shared between processes
https://www.postgresql.org/docs/current/parallel-query.html https://www.postgresql.org/docs/current/parallel-query.html
"PostgreSQL can devise query plans that can leverage multiple CPUs in order to answer queries faster."
- SigmundA 7mo agoNothing to do with plan caching, thats just talking about plan execution of parallel operations which is that thread or process based in PG? If process based then they can send small parts of plan across processes.
- hans_castorp 7mo agoAh, didn't see the caching part. Plans for prepared statements are cached though.
- AlisdairO 7mo agoOnly on a per-connection basis
- SigmundA 7mo agoYes if the client manually prepares the statement it will be cached for just that connection because in PG a connection is a process, but it won't survive from one connection to the next even in same process. Other databases like MSSQL have prepared statements but they are rarely used now days since plan caching based on query text was introduced decades ago.