Re: Using results from INSERT ... RETURNING

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: Using results from INSERT ... RETURNING
Дата
Msg-id 8F28E816-E2B0-4629-994E-1633187DA01B@gmail.com
обсуждение исходный текст
Ответ на Re: Using results from INSERT ... RETURNING  (David Fetter <david@fetter.org>)
Список pgsql-hackers
On Oct 4, 2009, at 1:24 PM, David Fetter <david@fetter.org> wrote:

> On Sun, Oct 04, 2009 at 01:16:50PM -0400, Tom Lane wrote:
>> Marko Tiikkaja <marko.tiikkaja@cs.helsinki.fi> writes:
>>> If I understood you correctly, this would imply that you wouldn't
>>> be able to do for example:
>>
>>> INSERT INTO foo
>>> WITH t AS ( DELETE FROM bar RETURNING * )
>>> SELECT * FROM t;
>>
>> Um ... forget what I said --- not enough caffeine yet, apparently.
>>
>> Yeah, rewrite rules are going to be a *serious* stumbling block to
>> this whole concept.
>
>> Maybe we should just punt the project until we have a clear idea of
>> how to do that.

This was discussed a bit upthread and doesn't seem obviously  
unmanageable to me.

> Maybe rewrite rules just don't fit with this feature, and should cause
> an error.  We have other things that don't work together, and the
> world hasn't ended yet.

That doesn't seem very satisfactory.

...Robert
>


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

Предыдущее
От: David Fetter
Дата:
Сообщение: Re: Using results from INSERT ... RETURNING
Следующее
От: Jeff Davis
Дата:
Сообщение: Re: COPY enhancements