model-writtenrun 4963 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Luca Ferrari reported that MERGE returned “MERGE 2” when both branches used DO NOTHING, although the documentation described the count as rows changed #1.
- Luca Ferrari also demonstrated that the same command returned “MERGE 0” with an empty target table, exposing inconsistent counting between matched and unmatched rows #1.
- Alvaro Herrera agreed that zero was the documented result and supplied a patch excluding CMD_NOTHING actions from the matched-row processed count #2.
- Alvaro Herrera committed the patch from #2 unchanged as 6ff5aa1299, with the commit message specifying a backpatch to PostgreSQL 15.
- Alvaro Herrera confirmed that the fix had been pushed and thanked the reporter, closing the thread with the sole submitted patch landed #3.