Re: Recording how a table is used
От | nha |
---|---|
Тема | Re: Recording how a table is used |
Дата | |
Msg-id | 4A547696.50704@free.fr обсуждение исходный текст |
Ответ на | Re: Recording how a table is used (nha <lyondif02@free.fr>) |
Список | pgsql-sql |
Hello, Le 8/07/09 11:30, nha a écrit : > Hello, > > Le 30/06/09 8:47, Daniel Gordon a écrit : >> I'm trying to record the results of a select statement into a separate >> table. I need the information selected, the column it was stored in, >> the table it was stored in, and the query that selected it. >> [...] >> Here is the table I'm trying to fill, in case it is useful >> >> create table sql_query_data_log ( >> id serial, >> create_ time timestamp DEFAULT now(), >> query varchar, >> table text, >> column text, >> >> data varchar >> ); >> [...] > Another crude alternative may be based on triggers as you mentioned. > Triggers may be created on each table for each possible triggered event > (before, after). > [...] Rules may be also appropriate (more than triggers?). This page gives some examples: http://www.postgresql.org/docs/8.3/interactive/rules-update.html Regards. -- nha / Lyon / France.
В списке pgsql-sql по дате отправления: