How to add a column
Add a column in PostgreSQL safely under load using lock_timeout, retries, DEFAULT and NOT NULL rules, and backfilling.
Add a column in PostgreSQL safely under load using lock_timeout, retries, DEFAULT and NOT NULL rules, and backfilling.
Follow these steps if you need to change a Postgres parameter (a.k.a., GUC, Grand Unified Configuration) for permanent effect.
Drop a PostgreSQL column safely without downtime using lock_timeout, retries, rollout order, and reclaiming disk space.
To monitor the progress of long-running index building or rebuilding, you can use this query:
Transaction ID and MultiXact ID wraparound – one of the worst incidents that can happen with a Postgres database. Infamous cases:
Speed up PostgreSQL pg_dump for large databases using parallel jobs (-j), compression tuning, direct piping without disk I/O, and large-table strategies.
LSN – Log Sequence Number, a pointer to a location in the Write-Ahead Log (WAL).
psql is a native terminal-based client for PostgreSQL.
psql has internal help – command \?; it's worth remembering and using it as a starting point when working with psql.
Some time ago (Jan 2024), on HackerNews, an article by knock.app was discussed, on zero downtime Postgres upgrades.
Ok, you've asked – here it is, a draft recipe to use UUIDv7 and partitioning (we'll use @TimescaleDB).