Re: INSERT... RETURNING with a function

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: INSERT... RETURNING with a function
Дата
Msg-id 4080.1253991454@sss.pgh.pa.us
обсуждение исходный текст
Ответ на INSERT... RETURNING with a function  (Iain Barnett <iainspeed@gmail.com>)
Список pgsql-general
Iain Barnett <iainspeed@gmail.com> writes:
> I've written a straightforward insert function, but using the
> RETURNING keyword for the first time. If I try running the test case
> I get the error:

> ERROR:  query has no destination for result data
> CONTEXT:  PL/pgSQL function "nonauth_users_insert_new_udf" line 7 at
> SQL statement

I think you want INSERT ... RETURNING ... INTO some-plpgsql-variable;

            regards, tom lane

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

Предыдущее
От: Adrian Klaver
Дата:
Сообщение: Re: INSERT... RETURNING with a function
Следующее
От: Gerhard Wiesinger
Дата:
Сообщение: Re: pg_buffercache - A lot of "unnamed" relfilenodes?