Hi there, new here and have question

Поиск
Список
Период
Сортировка
От Hendra
Тема Hi there, new here and have question
Дата
Msg-id 48730fa2.1d078e0a.489c.ffffe00c@mx.google.com
обсуждение исходный текст
Ответы Re: Hi there, new here and have question  (Asche <asche.public@mac.com>)
Re: Hi there, new here and have question  (Asche <asche.public@mac.com>)
Re: Hi there, new here and have question  (Charles Simard <tech@denarius.ca>)
Список pgsql-general

Hi Everyone.
I'm just subscribe to the mailing list
I'm new to Postgresql and
I have a question

I intend to make a function that returns more than a row
I tried something like below

create function listofemployeebasedondepartment(id_dept int) $$
declare
 resultset ??;
begin
    select * into resultset from employee where id_dept = id_dept;
    return resultset;
end
$$ language 'plpgsql';

I believe you get what I want
But I just couldn't finish the code since I miss something
I manage to find 'setof' but have no idea on how to use it

Any suggestion everyone?

Thank you,
Regards,
Hendra

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

Предыдущее
От: Scott Frankel
Дата:
Сообщение: roll back to 8.1 for PyQt driver work-around
Следующее
От: Michael Enke
Дата:
Сообщение: PG_MODULE_MAGIC lost if strip the object file