model-writtenrun 4366 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Tom Lane reported that MERGE inside a SQL-standard function body made function display and pg_dump fail because ruleutils lacked decompilation support, creating urgency before the upcoming releases #1.
- Alvaro Herrera investigated and supplied an initial implementation adapted from INSERT and UPDATE deparsing, with regression tests but acknowledged omissions #2 #3.
- Tom Lane completed OVERRIDING support, corrected pretty-printing, and expanded the tests to cover additional actions while moving them into rules.sql; the revised patch retained Alvaro's implementation approach #4.
- Michael Paquier reviewed the revised patch positively but noted missing OVERRIDING USER VALUE coverage; Tom initially considered additional coverage unnecessary, although the committed test ultimately switched to that variant #5 #6.
- Tom committed the revised patch with only that test adjustment on the development branch as 41e2c52fd6 and backported the same change to PostgreSQL 15 as f200b9695f, explaining that time was running out for buildfarm testing before version 15.3 #8.
- After landing, Alvaro reported that broader deparsing checks across MERGE and other optimizable commands found no crashes or visibly incorrect output; automated reparsing comparisons remained an unimplemented testing idea, with no outstanding patch reported #10.