Re: Rules on Select

From: "Hogan, James F(dot) Jr(dot)" <JHogan(at)seton(dot)org>
To: "Sean Hamilton" <sehamilt(at)chfund(dot)org>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: Rules on Select
Date: 2006-05-05 21:50:35
Message-ID: D73D467FE58F004E9D3FA25414945DC104FE0E0F@AUSEX3VS1.seton.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Sean,

I am looking to do the same thing...

I have so far posted with little relevant response to pgsql-admin,
pgsql-general and pgsql-sql

If you get any help please forward my way...

I will do the same..

What I can tell you is that it is possible to write the Select
Statements submitted to the Postgres Log Files...

The only way I can think of to accomplish our task would be to set
Logging to ALL and then parse the Log Files into a Table...

This is not an option I wish to pursue though it may work for you.

Jim

See my original post to this list :
From: "Hogan, James F. Jr." <JHogan ( at ) seton ( dot ) org>
To: <pgsql-sql ( at ) postgresql ( dot ) org>, <pgsql-general ( at )
postgresql ( dot ) org>
Subject: audit table containing Select statements submitted
Date: Thu, 4 May 2006 12:45:59 -0500

-----Original Message-----
From: pgsql-general-owner(at)postgresql(dot)org
[mailto:pgsql-general-owner(at)postgresql(dot)org] On Behalf Of Sean Hamilton
Sent: Friday, May 05, 2006 3:48 PM
To: pgsql-general(at)postgresql(dot)org
Subject: [GENERAL] Rules on Select

I have to log each time a user selects data from a table by inserting
record in another table.
For example
I have table xzy
user test selects id, name from table xyz.
I want to insert into table xyz_log
user, action, fields, timestamp
test, select, id name, 12/1/05 02:00:21

How can i do this using a Rule or Trigger?

Thanks

---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
message can get through to the mailing list cleanly

Browse pgsql-general by date

  From Date Subject
Next Message Tzahi Fadida 2006-05-05 21:57:46 Google Summer of Code: Full Disjunctions
Previous Message Volkan YAZICI 2006-05-05 21:46:01 intarray internals