Re: MERGE Specification

Поиск
Список
Период
Сортировка
От Simon Riggs
Тема Re: MERGE Specification
Дата
Msg-id 1208827710.4259.979.camel@ebony.site
обсуждение исходный текст
Ответ на Re: MERGE Specification  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: MERGE Specification  (Alvaro Herrera <alvherre@commandprompt.com>)
Re: MERGE Specification  (Gregory Stark <stark@enterprisedb.com>)
Список pgsql-hackers
On Mon, 2008-04-21 at 20:28 -0400, Tom Lane wrote:
> Simon Riggs <simon@2ndquadrant.com> writes:
> > On Mon, 2008-04-21 at 16:38 -0400, A.M. wrote:
> >> "MERGE will not invoke Rules." Does this imply that MERGE cannot be  
> >> used on views or that the resulting INSERTs or UPDATEs do not work on  
> >> views?
> 
> > Yes, that's right. Just like COPY.
> 
> I find this to be pretty ugly.  COPY is a special case because
> (a) it is a utility statement not a plannable one, and (b) its only
> reason to exist is to transfer data as fast as possible, so bypassing
> rules isn't an unreasonable restriction.  MERGE has neither of those
> properties, and thus arguing that it can or should be like COPY is an
> entirely unconvincing proposition. 

Unrelated to rule processing, you did read the bit about MERGE and race
conditions? ISTM that MERGE as it stands isn't very useful for anything
other than large data loads since its going to cause problems if used
concurrently.

--  Simon Riggs 2ndQuadrant  http://www.2ndQuadrant.com



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

Предыдущее
От: Simon Riggs
Дата:
Сообщение: Re: MERGE Specification
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: MERGE Specification