model-writtenrun 2468 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Richard Guo opened the thread with a wrong-result case discovered by Dean Rasheed: after subquery pullup, identical Var expressions could match the wrong grouping-set output, causing incorrect HAVING filtering #1; Richard then demonstrated the same problem in target-list expressions #2.
- Richard proposed removing redundant wrap_non_vars assignments for appendrel children because perform_pullup_replace_vars resets the setting before use #3, and Dean agreed while identifying the same cleanup in pull_up_constant_function #4.
- Richard submitted a two-patch series that separated the cleanup from the correctness fix, replacing the wrapping boolean with an enum so grouping sets wrap every output while full-join quals require wrapping variable-free expressions #5.
- The initial implementation retained separate Var and PlaceHolderVar handling because general-expression handling could introduce unnecessary nested placeholders and change regression plans #5; Dean tested the series successfully and requested clearer comments, better placement of cleanup comments, and registration of the new enum for pgindent #6.
- Richard incorporated those light revisions and proposed avoiding backpatches because the cleanup was cosmetic and the correctness fix lacked field reports and sufficient confidence for stable branches #7; Dean approved the revised series and supported that assessment #8.
- Richard committed both patches from #7 unchanged apart from rebase offsets: the appendrel cleanup as 4c49611715 and the grouping-sets fix as cc5d98525d.
- The thread ended with Richard confirming that both changes had landed on master without backpatching, leaving stable-branch fixes for reconsideration if field complaints arrived, ideally after a full beta test cycle #9.