Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 7FB671337B97 for ; Tue, 25 Jan 2011 11:23:13 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 48915-04 for ; Tue, 25 Jan 2011 15:23:08 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from servidor.grupo-nexcom.com (servidor.grupo-nexcom.com [212.230.51.188]) by mail.postgresql.org (Postfix) with ESMTP id 16D6E1337B99 for ; Tue, 25 Jan 2011 11:23:06 -0400 (AST) Received: from localhost (localhost.localdomain [127.0.0.1]) by servidor.grupo-nexcom.com (Postfix) with ESMTP id 36A964A1C04 for ; Tue, 25 Jan 2011 16:23:06 +0100 (CET) Received: from servidor.grupo-nexcom.com ([127.0.0.1]) by localhost (servidor.grupo-nexcom.com [127.0.0.1]) (amavisd-new, port 10024) with SMTP id qh2ZozcIKOXa for ; Tue, 25 Jan 2011 16:23:06 +0100 (CET) Received: from [192.168.200.195] (unknown [192.168.200.195]) by servidor.grupo-nexcom.com (Postfix) with ESMTP id 19B354A1C02 for ; Tue, 25 Jan 2011 16:23:06 +0100 (CET) Message-ID: <4D3EEABD.3080703@adinf.es> Date: Tue, 25 Jan 2011 16:22:37 +0100 From: MoNiLlO User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; es-ES; rv:1.9.2.9) Gecko/20100915 Lightning/1.0b2 Thunderbird/3.1.4 MIME-Version: 1.0 To: pgsql-sql@postgresql.org Subject: Re: Control reached end of trigger procedure without RETURN References: <397A0940-896A-4DEF-873A-907976E8400B@adinf.es> <4D3E9764.8050904@adinf.es> <20377.1295968006@sss.pgh.pa.us> In-Reply-To: <20377.1295968006@sss.pgh.pa.us> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-5 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201101/83 X-Sequence-Number: 35030 El 25/01/2011 16:06, Tom Lane escribi=F3: > MoNiLlO writes: >> When I launch one insert returns error: >> I put the function and the returned error. >> CREATE OR REPLACE FUNCTION ventas_det_a_ventas_imp() >> RETURNS trigger AS >> ... >> ERROR: control reached end of trigger procedure without RETURN >> CONTEXT: PL/pgSQL function "ventas_imp_a_ventas_cab" > The function that's lacking a RETURN is not the one you're showing us. > > regards, tom lane > Thanks for open my eyes. Great stupidity to mine. This is a second trigger that has no code and therefore there is no return. I feel the lost of time. Best regards.