Re: [GENERAL] Best way to monitor, control, or rewrite data definition commands?

2009-05-27 Thread Turner, Ian
[mailto:ejo...@engineyard.com] Sent: Friday, May 15, 2009 6:19 PM To: Turner, Ian Cc: pgsql-general@postgresql.org Subject: Re: [GENERAL] Best way to monitor, control, or rewrite data definition commands? On May 14, 2009, at 2:38 PM, Turner, Ian wrote: Thanks everyone for the many

Re: [GENERAL] Best way to monitor, control, or rewrite data definition commands?

2009-05-15 Thread Erik Jones
On May 14, 2009, at 2:38 PM, Turner, Ian wrote: Thanks everyone for the many responses to this question. Asynchronous schema updates may be how we'll have to proceed, but we'd really like to avoid that. Instead, I'm currently studying the possibility of a my_create_table() function that

Re: [GENERAL] Best way to monitor, control, or rewrite data definition commands?

2009-05-14 Thread Turner, Ian
: [GENERAL] Best way to monitor, control, or rewrite data definition commands? On Tue, 12 May 2009, Turner, Ian wrote: Is there any way to be notified when a user executes data definition commands such as CREATE TABLE? It doesn't appear possible to apply triggers or rules to the system

[GENERAL] Best way to monitor, control, or rewrite data definition commands?

2009-05-12 Thread Turner, Ian
Hello list, I am trying to implement automatic audit log tracking for newly created tables. When a user creates a table, I would like to create a second table for the audit log, along with the relevant rules. So for example, if a user does CREATE TABLE foo (fooid integer); Then I would also

Re: [GENERAL] Best way to monitor, control, or rewrite data definition commands?

2009-05-12 Thread Greg Smith
On Tue, 12 May 2009, Turner, Ian wrote: Is there any way to be notified when a user executes data definition commands such as CREATE TABLE? It doesn't appear possible to apply triggers or rules to the system tables, and the query rewrite engine only seems to apply to SELECT, INSERT, and UPDATE.

Re: [GENERAL] Best way to monitor, control, or rewrite data definition commands?

2009-05-12 Thread John DeSoi
On May 12, 2009, at 7:59 PM, Turner, Ian wrote: CREATE TABLE foo (fooid integer); Then I would also like to do CREATE TABLE foo_audit (fooid integer, other columns); along with the creation of some other triggers, rules, etc. Is there any way to be notified when a user executes data