Search Postgresql Archives

Re: log_statement GUC parameter

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



[ dept. of second thoughts ]

Adrian Klaver <adrian.klaver@xxxxxxxxxxx> writes:
> On 8/12/21 1:19 PM, Mladen Gogala wrote:
>> The idea is to log all statements by the particular user, not by 
>> everybody.

> Would pg_stat_statements work for you?:
> https://www.postgresql.org/docs/current/pgstatstatements.html

Actually, for that specific requirement, there's an easier way:

	ALTER USER target_user SET log_statement = 'all';

While the target_user can't do that for himself, a superuser
can.

			regards, tom lane





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux