Re: Update en Trigger Volatile

From: Jaime Casanova <systemguards(at)gmail(dot)com>
To: Juan Pablo Yañez <jyanez(at)sigma(dot)gov(dot)bo>
Cc: pgsql-es-ayuda <pgsql-es-ayuda(at)postgresql(dot)org>
Subject: Re: Update en Trigger Volatile
Date: 2005-06-10 16:17:17
Message-ID: c2d9e70e0506100917d8c8829@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-es-ayuda

On 6/10/05, Juan Pablo Yañez <jyanez(at)sigma(dot)gov(dot)bo> wrote:
> Hola a todos, tengo el siguiente trigger
>
> CREATE TRIGGER egabenef_val_general BEFORE INSERT OR UPDATE
> ON ejecucion_gastos_benef FOR EACH ROW
> EXECUTE PROCEDURE egaben_val_general();
>
> que llama a la siguiente funcion declarada como VOLATILE:
>
> CREATE OR REPLACE FUNCTION egaben_val_general() RETURNS trigger AS
[...]
> LANGUAGE 'plpgsql' VOLATILE CALLED ON NULL INPUT SECURITY INVOKER;
>
> pero en el momento del INSERT o UPDATE, me devuelve el siguiente mensaje
> de error:
>
> ERROR: UPDATE is not allowed in a non-volatile function.
>

algo no me gusta.... creastes la funcion como volatile???

Haz esto, borra el trigger, borra la funcion, vuelve a crear la
funcion, vuelve a crear el trigger y verifica que de hecho la estas
creando como volatile...

Cuentanos el resultado... segun eso puede resultar ser un bug...
BTW, no nos has dicho la version de postgres ni SO

--
Atentamente,
Jaime Casanova
(DBA: DataBase Aniquilator ;)

In response to

Responses

Browse pgsql-es-ayuda by date

  From Date Subject
Next Message Lucas Hernandez 2005-06-10 16:19:30 Re: Hola buenos Dias? Es pecado pedir ayuda?
Previous Message Juan Pablo Yañez 2005-06-10 15:52:50 Update en Trigger Volatile