Re: [GENERAL] 'Select INTO" in Execute (dynamic query )

Поиск
Список
Период
Сортировка
Искать
От
Tom Lane
Тема
Re: [GENERAL] 'Select INTO" in Execute (dynamic query )
Дата
Msg-id
23848.1113845209@sss.pgh.pa.us
Ответ на
Список
Дерево обсуждения
'Select INTO" in Execute (dynamic query ) "Dinesh Pandey" <dpandey@secf.com>
Re: [GENERAL] 'Select INTO" in Execute (dynamic query ) Tom Lane <tgl@sss.pgh.pa.us>
"Dinesh Pandey"  writes:
> What's wrong with this code (ERROR:  syntax error at or near "INTO" at
> character 8)?

You can't use plpgsql's SELECT INTO in an EXECUTE'd command, because
SELECT INTO means something entirely different to the main SQL engine.

The usual workaround is to use FOR ... IN EXECUTE.  See the plpgsql docs.

			regards, tom lane
В списке pgsql-sql по дате отправления
От: Dinesh Pandey
Дата:
От: A. Kulikov
Дата:
Сообщение: User Defined Functions Errors
FAQ