Re: MERGE output doubt

Alvaro Herrera <alvherre@alvh.no-ip.org>

From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: Luca Ferrari <fluca1978@gmail.com>
Cc: pgsql-general <pgsql-general@lists.postgresql.org>
Date: 2022-11-17T17:57:33Z
Lists: pgsql-general
On 2022-Nov-17, Alvaro Herrera wrote:

> On 2022-Oct-20, Luca Ferrari wrote:
> 
> > I was expecting an output tag like "MERGE 0" since both branches have
> > "do nothing", so no tuples should be updated at all on the target
> > table.
> 
> Hmm, yeah, it should report 0 tuples, according to the documentation.
> AFAICS this patch fixes it, will push shortly.

Pushed, thanks for reporting.

-- 
Álvaro Herrera         PostgreSQL Developer  —  https://www.EnterpriseDB.com/
"Someone said that it is at least an order of magnitude more work to do
production software than a prototype. I think he is wrong by at least
an order of magnitude."                              (Brian Kernighan)



Commits

  1. Fix MERGE tuple count with DO NOTHING