Обсуждение: ALTER ROLE foo SET log_connections = true;

Поиск
Список
Период
Сортировка

ALTER ROLE foo SET log_connections = true;

От
"Marc Mamin"
Дата:

Hello,

if I try to SET log_connections = true

(as super user,  for another role)

 I get the error: parameter "log_connections" cannot be set after connection start.

I find it a bit surprising as this wouldn't  affect the current session.

best regards,

Marc Mamin

 

Re: ALTER ROLE foo SET log_connections = true;

От
Raghavendra
Дата:
Yep, it cannot be changed at session-level.

http://www.postgresql.org/docs/9.1/static/runtime-config-logging.html 

---
Regards,
Raghavendra
EnterpriseDB Corporation



On Fri, Mar 16, 2012 at 5:24 PM, Marc Mamin <M.Mamin@intershop.de> wrote:

Hello,

if I try to SET log_connections = true

(as super user,  for another role)

 I get the error: parameter "log_connections" cannot be set after connection start.

I find it a bit surprising as this wouldn't  affect the current session.

best regards,

Marc Mamin

 


Re: ALTER ROLE foo SET log_connections = true;

От
Tom Lane
Дата:
"Marc Mamin" <M.Mamin@intershop.de> writes:
> if I try to SET log_connections = true
> (as super user,  for another role)
>  I get the error: parameter "log_connections" cannot be set after
> connection start.

Yeah ...

> I find it a bit surprising as this wouldn't  affect the current session.

Nor would it affect any other session, so the error is to let you know
you're doing something useless/ineffective.

            regards, tom lane