Re: problem with pl/pgsql

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Ben <bench(at)silentmedia(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: problem with pl/pgsql
Date: 2003-04-17 14:11:56
Message-ID: 10325.1050588716@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Ben <bench(at)silentmedia(dot)com> writes:

> CREATE or REPLACE FUNCTION Fetch_ArtistSet_By_Artists(integer[]) RETURNS setof integer AS
> 'DECLARE
> ...
> r record;
> ...
> RETURN next r;

I think you probably need "RETURN next r.setID", since r is a record not
an integer. The error message seems kind of unhelpful though :-(

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Benjamin RICHARD 2003-04-17 14:27:57 Using array parameter in Functions plpgsql
Previous Message Georg Steffers 2003-04-17 14:07:18 Re: problem with pl/pgsql