Re: Problems with stored procedure (function)

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Problems with stored procedure (function)
Дата
Msg-id 9952.1261164800@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Problems with stored procedure (function)  (Marco Craveiro <marco.craveiro@gmail.com>)
Ответы Re: Problems with stored procedure (function)  (Marco Craveiro <marco.craveiro@gmail.com>)
Список pgsql-novice
Marco Craveiro <marco.craveiro@gmail.com> writes:
> The problem I have is my function keeps on returning a single column
> with the name of the function, rather than something akin to the table
> I've defined:

> sanzala=# select load_country();
>     load_country
> --------------------
>  (a,"b ","c  ",123)
> (1 row)

Yes, because that's what that syntax says to do: return one
composite-type column.  The easiest way to expand it is

    select * from load_country();

            regards, tom lane

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

Предыдущее
От: Marco Craveiro
Дата:
Сообщение: Problems with stored procedure (function)
Следующее
От: Marco Craveiro
Дата:
Сообщение: Re: Problems with stored procedure (function)