pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andrew Sullivan <ajs@crankycanuck.ca>
To: pgsql-admin@postgresql.org
Subject: Re: trigger ddl actions in a table
Date: Thu, 15 Nov 2007 10:38:28 -0500
Message-ID: <20071115153828.GF20228@crankycanuck.ca> (raw)
In-Reply-To: <1C2329C9430609409808ECF10237287612EA4CC7@mydomain.com>
References: <1C2329C9430609409808ECF10237287612EA4CC7@mydomain.com>

On Thu, Nov 15, 2007 at 04:29:51PM +0100, "König, Monika" wrote:
> I can see all ddl in my log files, but 
> 	- there are even the errors in and 
> 	- i can't use it for a select

There are logging options that should allow you to collect the DDL and then
parse it.  You could then load it into a table.  But to answer your
question,

> Is there an possibility for having such an system-action table??

you cannot today have triggers on system tables, and AFAIK nobody has
contributed a DDL-audit capability yet.  IMO the safest (i.e. least subject
to attack) way to do this would be to pull it out of the WAL on another
machine.  Given that we already have PITR, the data must be in there (maybe
not with a wallclock time, but with relative time).  It seems this is
something that could be added, if someone were to do the work.  I am not
aware that anyone is doing it at the moment, but I bet there are developers
who will work for sponsorship :)

A

-- 
Andrew Sullivan
Old sigs will return after re-constitution of blue smoke



view thread (4+ messages)  latest in thread

Message-ID: <20071115153828.GF20228@crankycanuck.ca>
Permalink:  ../20071115153828.GF20228@crankycanuck.ca/
Also on:    postgresql.org/message-id/20071115153828.GF20228@crankycanuck.ca

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: ajs@crankycanuck.ca
  Subject: Re: trigger ddl actions in a table
  In-Reply-To: <20071115153828.GF20228@crankycanuck.ca>
  References: <1C2329C9430609409808ECF10237287612EA4CC7@mydomain.com> <20071115153828.GF20228@crankycanuck.ca>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox