Re: tabla de auditoría

From: Lazaro Ruben Garcia Martinez <lgarciam(at)uci(dot)cu>
To: npolanco(at)cuij(dot)edu(dot)cu
Cc: pgsql-es-ayuda <pgsql-es-ayuda(at)postgresql(dot)org>
Subject: Re: tabla de auditoría
Date: 2012-05-02 12:50:48
Message-ID: 2be4e297-a675-447a-9998-35837f89f9cb@ucimail3.uci.cu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-es-ayuda

Pudieras utilizar tablelog, para lo que deseas hacer.

http://pgfoundry.org/projects/tablelog/

Saludos.

----- Mensaje original -----

> Hola a todos, tengo una BD en la que quiero registrar en una tabla
> las operaciones que se realizan en las otras, la cual tiene la
> siguiente estrucctura:

> CREATE TABLE operaciones_tablas
> (
> id_operacion bigint NOT NULL,
> fecha_operacion date, //FECHA DE ACTUALIZACIÓN
> id_especialista integer, //RESPONSABLE DE LA ACTUALIZACIÓN
> tipo_operacion character varying(7), //INSERT, DELETE O UPDATE
> tabla_operada character varying(30) //NOMBRE DE LA TABLA ACTUALIZADA
> )

> Tengo mis dudas de como obtener los dos últimos datos, no se como
> obtener el nombre de la tabla que se actualiza ni el tipo de
> operación que se realiza, estuve pensando a través de los triger
> pero no di con nada.

> Alguien me puede ayudar en esto, se lo agradecería en el alma.

> Muchísimas gracias de ante mano.
> -
> Enviado a la lista de correo pgsql-es-ayuda
> (pgsql-es-ayuda(at)postgresql(dot)org)
> Para cambiar tu suscripci�n:
> http://www.postgresql.org/mailpref/pgsql-es-ayuda

> 10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS
> INFORMATICAS...
> CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION

> http://www.uci.cu
> http://www.facebook.com/universidad.uci
> http://www.flickr.com/photos/universidad_uci

10mo. ANIVERSARIO DE LA CREACION DE LA UNIVERSIDAD DE LAS CIENCIAS INFORMATICAS...
CONECTADOS AL FUTURO, CONECTADOS A LA REVOLUCION

http://www.uci.cu
http://www.facebook.com/universidad.uci
http://www.flickr.com/photos/universidad_uci

In response to

Responses

Browse pgsql-es-ayuda by date

  From Date Subject
Next Message carlos.perez 2012-05-02 12:58:49 Re: tabla de auditoría
Previous Message Alejandro Carrillo 2012-05-02 12:37:35 Re: [pgsql-es-ayuda] RE: [pgsql-es-ayuda] ¿Como detecto si un UPDATE modifica un campo en especifico?