SQL vs PL/pgSQL in PostgreSQL: Plan Caching
SQL vs PL/pgSQL functions in PostgreSQL 16: why a SQL function is re-planned on every loop call, how to reduce plan time.
Author
Founder, CortexRidge
15+ years leading database engineering teams. Built and operated PostgreSQL platforms across AWS, Oracle (OCI PostgreSQL), Tessell, OpenSCG, and EnterpriseDB. Author of the PL/pgSQL book. Now building CortexBolt at CortexRidge.
SQL vs PL/pgSQL functions in PostgreSQL 16: why a SQL function is re-planned on every loop call, how to reduce plan time.
Use PostgreSQL ALTER FUNCTION SET work_mem to stop one function's sorts spilling to disk without a global change. A production fix: 150 GB a day to 0.
pgsonify is an experimental MIT-licensed tool that sonifies PostgreSQL health metrics as real elephant recordings. How it maps stats views to sound.
One webhook call checks a server's disk, records the reading, alerts the customer, and archives the run. A five-node CortexBolt workflow, step by step.
What does it cost to store and index embeddings in pgvector? Four costs priced per vector, and why keeping the HNSW index in RAM is the one that sets the bill.
PostgreSQL LISTEN/NOTIFY loses messages when nobody is listening. See how pg_durable adds durable signals and workflows that survive restarts.
Fifteen years of database platforms at AWS, Oracle, Tessell, OpenSCG, and EnterpriseDB — and how they became CortexBolt, the autonomous operations platform.