model-writtenrun 9373 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Shohei Mochizuki reported that postgres_fdw discarded BEFORE ROW UPDATE trigger changes to columns absent from the UPDATE target list and supplied a fix transmitting all columns when such triggers exist; determining precisely which columns a trigger changes would require execution-time information #1.
- Amit Langote reviewed the fix and considered constructing remote queries during execution, but noted the additional complexity and possible need for a different query for every row; the patch retained the simpler planning-time approach #2.
- Tom Lane raised the possibility that triggers also needed columns omitted from remote fetches, which Amit showed was already handled by the whole-row target entry for foreign tables with row triggers; Shohei separately checked that AFTER-trigger RETURNING requirements were already covered #3 #4 #5.
- Amit and Etsuro Fujita clarified that UPDATE fetches unassigned columns even without triggers, while row triggers require fetching all columns, resolving their disagreement without changing the patch #9 #11 #12 #13.
- Etsuro posted a revision retaining Shohei's implementation and tests, improving its explanatory comment and adding a commit message, with plans to backpatch through PostgreSQL 9.4; Amit requested a further wording correction that Etsuro accepted #14 #15 #16.
- Etsuro committed the revised patch as 8b6da83d16, incorporating Amit's comment correction and adding an EXPLAIN regression check so PostgreSQL 9.4 would also have plan coverage #18.
- The thread ended with Shohei acknowledging the commit, with the fix landed and no outstanding work identified #19.