Re: why doesn't insert into foo delete from bar returning baz work? - Mailing list pgsql-general

From Merlin Moncure
Subject Re: why doesn't insert into foo delete from bar returning baz work?
Date
Msg-id AANLkTikOiEYBjgTOALdZOFiVMlPXgYZC0mtAjr1pUF9Q@mail.gmail.com
Whole thread Raw
In response to why doesn't insert into foo delete from bar returning baz work?  (Palle Girgensohn <girgen@pingpong.net>)
List pgsql-general
On Wed, May 26, 2010 at 11:17 AM, Palle Girgensohn <girgen@pingpong.net> wrote:
> While you can do
>
> insert into foo (a, b) select a, b from bar;
>
> and
>
> delete from bar where a=1 returning a, b;
>
> it fails to run
>
> insert into foo (a, b) delete from bar where a=1 returning a, b;
>
> This is not what I would expect. Is there a reason for it not working?

everyone wants this.  it was slated to be included for 9.0 but the
patch had to be pulled due to technical problems.

merlin

pgsql-general by date:

Previous
From: Steve Crawford
Date:
Subject: Re: reducing postgresql disk space
Next
From: Merlin Moncure
Date:
Subject: Re: Transaction with in function