Hello
2012/10/21 Scott Ribe <[email protected]>:
> Briefly, what would it take to make the following work?
>
> create function getbatch (variadic ids int8[]) returns setof foobar as $$
> begin
> return query
> select * from foobar where id in (ids);
> end;
> $$ language plpgsql;
>
create function getbatch (variadic ids int8[]) returns setof foobar as $$
begin
return query
select * from foobar where id = any (ids);
end;
$$ language plpgsql;
note, for these single statement function, sql language is better
regards
Pavel Stehule
> --
> Scott Ribe
> [email protected]
> http://www.elevated-dev.com/
> (303) 722-0567 voice
>
>
>
>
>
>
> --
> Sent via pgsql-general mailing list ([email protected])
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
--
Sent via pgsql-general mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general