Doh, somehow I forgot the patches once again. Here they are. I intend to push 0001 to all relevant branches soon, then park the rest until we have ALTER TABLE ... ADD PRIMARY KEY USING INDEX.
pgsql-bugs by date:
Соглашаюсь с условиями обработки персональных данных