Re: Allow FDW extensions to support MERGE command via CustomScan

From: Matheus Alcantara <matheusssilv97(at)gmail(dot)com>
To: Önder Kalacı <onderkalaci(at)gmail(dot)com>
Cc: Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Allow FDW extensions to support MERGE command via CustomScan
Date: 2024-12-12 14:20:19
Message-ID: 0a216003-9998-4481-9062-4136cb926d39@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

Just some thoughts on documentation part.

> +</programlisting>
> +
> + Postgres doesn't support <command>MERGE</command> on foreign tables,
> + see <function>ExecMerge</function>. Still, extensions may provide
> + custom scan nodes to support <command>MERGE</command> on foreign
> + tables. If your extension provides such custom scan node, this
> + function should return true.
> + </para>

What's the point about mentioning the ExecMerge function? I didn't
find any relevant documentation about why it not support foreign
tables, maybe its because it should not?

I didn't understand what is a "custom scan node" on the fdw context at
first place (I don't know if it is an already know word on this
context), but from what I've understood so far, to a fdw extension
support MERGE it should implements on PlanForeignModify right? If
that's the case maybe it's worth updating the PlanForeignModify
documentation as well? It only mention insert, update, or delete
operations. Also, I don't know if would be good to link the
PlanForeignModify on this part of the documentation, WYT?

--
Matheus Alcantara
EDB: https://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message vignesh C 2024-12-12 14:54:32 Re: Memory leak in pg_logical_slot_{get,peek}_changes
Previous Message Yurii Rashkovskii 2024-12-12 14:02:46 Re: Add Postgres module info