Received: from localhost (maia-2.hub.org [200.46.204.187]) by postgresql.org (Postfix) with ESMTP id 839039FB639 for ; Mon, 28 May 2007 22:39:45 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.187]) (amavisd-maia, port 10024) with ESMTP id 92835-09 for ; Mon, 28 May 2007 22:39:36 -0300 (ADT) X-Greylist: delayed 00:06:39.264589 by SQLgrey-1.7.5 Received: from ns1.peker.com.pl (181-ego-2.acn.waw.pl [62.121.85.181]) by postgresql.org (Postfix) with SMTP id 768A09FB691 for ; Mon, 28 May 2007 22:39:41 -0300 (ADT) Received: (qmail 4019 invoked by uid 540); 29 May 2007 01:32:00 -0000 Received: from 83.143.210.69 by ns1.peker.com.pl (envelope-from , uid 401) with qmail-scanner-1.25st (clamdscan: 0.82/760. spamassassin: 3.0.2. perlscan: 1.25st. Clear:RC:1(83.143.210.69):. Processed in 0.078375 secs); 29 May 2007 01:32:00 -0000 Received: from host69-83-143-210.limes.com.pl (HELO ?10.0.1.69?) (informatyka-adamr@83.143.210.69) by ns1.peker.com.pl with SMTP; 29 May 2007 01:31:59 -0000 Message-ID: <465B82DF.1030908@informatyka.gdansk.pl> Date: Tue, 29 May 2007 03:33:19 +0200 From: =?UTF-8?B?QWRhbSBSYWTFgm93c2tp?= User-Agent: Thunderbird 2.0.0.0 (X11/20070326) MIME-Version: 1.0 To: Michael Fuhr CC: "Alexander B." , "pgsql-admin@postgresql.org" Subject: Re: Return record on recursive call References: <465B365F.2010605@yahoo.com.br> <20070528214007.GA65520@winnie.fuhr.org> In-Reply-To: <20070528214007.GA65520@winnie.fuhr.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200705/295 X-Sequence-Number: 25615 For info only (it's not exactly this same problem): This function looks like replacement of scroll cursor functionality. Cursors are working without problems. Adamn Michael Fuhr pisze: > On Mon, May 28, 2007 at 05:06:55PM -0300, Alexander B. wrote: >> I am creating a function that when finished the last level, should >> return for each row. >> I put raise notice to trace and the result is correct, but when I try to >> execute, an error is showed. >> >> "ERRO: wrong record type supplied in RETURN NEXT" >> >> I created other functions the same way and worked, basically using the >> same structure but not recursive. >> Is it different return when using recursive. > > It's hard to say what's wrong with your sample code without seeing > it with its surrounding context. Could you post a complete example? > Please reduce the problem to the smallest possible example that > exhibits the undesirable behavior. > > This question is a bit off-topic for pgsql-admin; you might get > more help on pgsql-general. >