Re: Fwd: Start up question about triggers

From: Scott Marlowe <smarlowe(at)g2switchworks(dot)com>
To: "Forums (at) Existanze" <forums(at)existanze(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Fwd: Start up question about triggers
Date: 2006-06-26 15:38:06
Message-ID: 1151336286.4215.35.camel@state.g2switchworks.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Mon, 2006-06-26 at 08:59, Forums @ Existanze wrote:
> Hello again,
>
> The problem is not tracking WHAT changed, this can be done, as we have
> discussed in this thread, the problem is how to replicate the necessary
> commands that will alter a mirror database to reflect what has been changed,
> sequencially and in the order that it has occurred.
>
> I you can find my first question (I can repost), you will see that this
> problem has arisen due of lack of proper design. This is a requirement that
> has just come into the picture and we have to find a solution for it.
>
> My initial question was intended to figure out a way to track these changes
> AND create the necessary INSERT,DELETE and UPDATE statements for each of the
> changes that occurr in the entire database. I wanted to avoid having to
> create an audit table for each of the tables in the database. At the moment
> we are counting 82, this will mean another 82 tables, along with 82 triggers
> and so on.

I'm having a mad scientist moment.

I bet it would be possible to hack pgpool to do this. Just have it
shoot all the queries that come in to it at the normal database, AND at
a text file or something like that.

Not sure that's any better than using pgsql logging to do the same
thing, but it certainly doesn't seem like it would be that hard to do.

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Andrew Sullivan 2006-06-26 18:24:45 Re: Fwd: Start up question about triggers
Previous Message Andrew Sullivan 2006-06-26 14:43:09 Re: Fwd: Start up question about triggers