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 docu
On 2022-Oct-20, Luca Ferrari wrote:
> Now, if I use a do nothing merge:
>
> estdb=> MERGE INTO average_scores a
> USING ( SELECT name, avg( score ) AS avg_score
>FROM scores GROUP BY name ) s
> ON s.name = a.name
> WHEN MATCHED THEN
>do nothing
> WHEN NOT MATCHED THEN
>do nothin