Doc: clarify locking requirements for ALTER TABLE ADD FOREIGN KEY.

Tom Lane <tgl@sss.pgh.pa.us>

Commit: a88e5886c59c0e1e01f424a1fcb477db82ddd3af
Author: Tom Lane <tgl@sss.pgh.pa.us>
Date: 2020-04-10T17:12:58Z
Releases: 12.3
Doc: clarify locking requirements for ALTER TABLE ADD FOREIGN KEY.

The docs explained that a SHARE ROW EXCLUSIVE lock is needed on the
referenced table, but failed to say the same about the table being
altered.  Since the page says that ACCESS EXCLUSIVE lock is taken
unless otherwise stated, this left readers with the wrong conclusion.

Discussion: https://postgr.es/m/834603375.3470346.1586482852542@mail.yahoo.com

Files

PathChange+/−
doc/src/sgml/ref/alter_table.sgml modified +13 −8

Documentation touched

Discussion