Re: support for MERGE

Поиск
Список
Период
Сортировка
От Álvaro Herrera
Тема Re: support for MERGE
Дата
Msg-id 202203091744.o27bb2gpex2j@alvherre.pgsql
обсуждение исходный текст
Ответ на Re: support for MERGE  (Zhihong Yu <zyu@yugabyte.com>)
Список pgsql-hackers
On 2022-Mar-07, Zhihong Yu wrote:

> For v13-0003-MERGE-SQL-Command-following-SQL-2016.patch :
> 
> +    * Reset per-tuple memory context to free any expression evaluation
> +    * storage allocated in the previous cycle.
> +    */
> +   ResetExprContext(econtext);
> 
> Why is the memory cleanup done in the next cycle ? Can the cleanup be done
> at the end of the current cycle ?

I have removed that, because Andres had already pointed out that it was
redundant with the reset done in the caller.

> +            * XXX Should this explain why MERGE has the same logic as UPDATE?
> 
> I think explanation should be given.

Actually, the routine in question is only handling insert, not UPDATE,
so MERGE is not relevant to the function.  I have removed the comment.
This was probably a leftover from work prior to 86dc90056dfd; that
commit made it all irrelevant.

-- 
Álvaro Herrera              Valdivia, Chile  —  https://www.EnterpriseDB.com/
"Ninguna manada de bestias tiene una voz tan horrible como la humana" (Orual)



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Magnus Hagander
Дата:
Сообщение: Re: Proposal: Support custom authentication methods using hooks
Следующее
От: Justin Pryzby
Дата:
Сообщение: Re: Adding CI to our tree