Re: log_statement per table

Поиск
Список
Период
Сортировка
От Venkata Balaji Nagothi
Тема Re: log_statement per table
Дата
Msg-id CAHBAh5t1d4Q6cacC-tdtr2m2sVBLWLju2tZhgWY1Y=mxOjP24g@mail.gmail.com
обсуждение исходный текст
Ответ на log_statement per table  (David Janssens <david.j@almacom.co.th>)
Список pgsql-general

On Tue, Mar 4, 2014 at 9:19 PM, David Janssens <david.j@almacom.co.th> wrote:
Hello,
I would like to log statements that modify a small subset of tables in a databases.
(not all tables, because the log files become too big in that case and I also worry about performance)
I currently use log_statement='mod' but I didn't find a way to limit this to the set of tables I want.
What is the best way to do this?

Not sure if this solution would help or may be you have already looked at this possibility.

If you know which user is performing the activities on those tables, you can look at the possibility of setting the log_statement='all' at a user level by saying "alter role <username> set log_statement='all' ". This would log all the statements executed by that particular user. You can think of doing this if you think do not end up having a big logfile.

Or

In my experience, i have configured a separate user with separate set of logging mechanism and use to monitor all the activities performed by that user.

Venkata Balaji N

Sr. Database Administrator
Fujitsu Australia 

В списке pgsql-general по дате отправления:

Предыдущее
От: Rob Sargent
Дата:
Сообщение: Re: Offending My Tender Sensibilities -OR- OLTP on a Star Schema
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: How to recovery failed master after failover