Capture insert returning

Поиск
Список
Период
Сортировка
От scorpdaddy@hotmail.com
Тема Capture insert returning
Дата
Msg-id BLU0-SMTP60973B8169016D96D718D0CEA70@phx.gbl
обсуждение исходный текст
Список pgsql-sql


Considering jdbc to pg8.4, is there a way to save results of "INSERT ... RETURNING *" to a temp table within the transaction, knowing that INSERT RETURNING is a pg specific augmentation to standard SQL.


This doesn't seem to work:


CREATE TEMP TABLE bar ON COMMIT DROP AS

INSERT INTO foo(a, b)

SELECT a, b FROM another_foo

RETURNING *;


The idea is to capture foo's pk, a, b in bar.


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

Предыдущее
От: msi77
Дата:
Сообщение: Re: Aggregates puzzle
Следующее
От: Anish Kejariwal
Дата:
Сообщение: pass in array to function for use by where clause? how optimize?