SET NULL concurrently
It would be nice to be able to do ALTER TABLE .. ALTER COLUMN .. SET NULL without scanning the entire table while holding a lock...
One idea is to allow skipping the scan if there's an existing constraint col IS NOT NULL or for that matter anything which can prove it such as col > x. Then users could do something like:
ALTER TABLE .. ADD CONSTRAINT temp_constraint CHECK col IS NOT NULL NOT VALID
UPDATE .. SET col = ... WHERE col IS NULL
ALTER TABLE VALIDATE CONSTRAINT temp_constraint
ALTER TABLE ALTER col SET NOT NULL
ALTER TABLE DROP CONSTRAINT temp_constraint