Re: Calling SQL functions from ECPG

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Calling SQL functions from ECPG
Дата
Msg-id 25615.1082519406@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Calling SQL functions from ECPG  ("Owens, Steve" <Steve.Owens@usa.xerox.com>)
Список pgsql-interfaces
"Owens, Steve" <Steve.Owens@usa.xerox.com> writes:
> EXEC SQL SELECT get_foo(1) INTO :record;

> I get a "ERROR: Cannot display record of type RECORD at line 26".

I know zip about ECPG, but I'd think a more likely bet is
EXEC SQL SELECT * INTO :record FROM get_foo(1);
orEXEC SQL SELECT * FROM get_foo(1) INTO :record;

depending on what your theology is about the placement of INTO.  The
point is that a function returning setof-record is a table source and
should appear in FROM.
        regards, tom lane


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

Предыдущее
От: "Owens, Steve"
Дата:
Сообщение: Calling SQL functions from ECPG
Следующее
От: bcsaba@balmazujvaros.hu
Дата:
Сообщение: BLIBPQ.LIB, BLIBPQDLL.LIB or LIBPQ 7.4 problem