Re: en que estoy fallando (sintaxis de funcion)

From: "Jaime Casanova" <systemguards(at)gmail(dot)com>
To: "jeferson alvarez" <jalvarez(at)renova(dot)com(dot)pe>
Cc: pgsql-es-ayuda(at)postgresql(dot)org
Subject: Re: en que estoy fallando (sintaxis de funcion)
Date: 2007-02-04 22:58:50
Message-ID: c2d9e70e0702041458l2953dda4uc4e45b36ab2c537f@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-es-ayuda

On 2/2/07, jeferson alvarez <jalvarez(at)renova(dot)com(dot)pe> wrote:
> CREATE OR REPLACE FUNCTION sgc_m_doc_base_buscar(tipo bpchar)
> RETURNS SETOF refcursor AS '
> DECLARE
> BEGIN
> IF $1=''NEN'' THEN
> OPEN nota FOR SELECT * FROM alma_m_nota_ing;

no has declarado nota

> RETURN NEXT;

return next que?

> ELSE
> OPEN notasal FOR SELECT * FROM alm_m_nota_salida;

no has declarado notasal

> RETURN NEXT;

return next que?

> END IF;
> RETURN;
> END;
> '
> LANGUAGE 'plpgsql' VOLATILE;
>
>

--
Atentamente,
Jaime Casanova

"Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs and the universe trying
to produce bigger and better idiots.
So far, the universe is winning."
Richard Cook

In response to

Browse pgsql-es-ayuda by date

  From Date Subject
Next Message David Primero Segundo 2007-02-05 07:54:54 RE: Gambas and Postgresql
Previous Message Jaime Casanova 2007-02-04 22:51:04 Re: sobre herencias