Hi Rahila, On Wed, Feb 24, 2021 at 3:07 PM Rahila Syed <rahilasye...@gmail.com> wrote: >> > I think the documentation update is missing from the patches. >> >> Hmm, I don't think we document the behavior that is improved by the v3 >> patches as a limitation of any existing feature, neither of foreign >> keys referencing partitioned tables nor of the update row movement >> feature. So maybe there's nothing in the existing documentation that >> is to be updated. >> >> However, the patch does add a new error message for a case that the >> patch doesn't handle, so maybe we could document that as a limitation. >> Not sure if in the Notes section of the UPDATE reference page which >> has some notes on row movement or somewhere else. Do you have >> suggestions? >> > You are right, I could not find any direct explanation of the impact of row > movement during > UPDATE on a referencing table in the PostgreSQL docs. > > The two documents that come close are either:
Thanks for looking those up. > 1. https://www.postgresql.org/docs/13/trigger-definition.html . > The para starting with "If an UPDATE on a partitioned table causes a row to > move to another partition" > However, this does not describe the behaviour of internal triggers which is > the focus of this patch. The paragraph does talk about a very related topic, but, like you, I am not very excited about adding a line here about what we're doing with internal triggers. > 2. Another one like you mentioned, > https://www.postgresql.org/docs/11/sql-update.html > This has explanation for row movement behaviour for partitioned table but > does not explain > any impact of such behaviour on a referencing table. > I think it is worth adding some explanation in this document. Thus, explaining > impact on referencing tables here, as it already describes behaviour of > UPDATE on a partitioned table. ISTM the description of the case that will now be prevented seems too obscure to make into a documentation line, but I tried. Please check. -- Amit Langote EDB: http://www.enterprisedb.com
v5-0001-Create-foreign-key-triggers-in-partitioned-tables.patch
Description: Binary data
v5-0002-Enforce-foreign-key-correctly-during-cross-partit.patch
Description: Binary data