Re: proposal: option --application_name for psql

From: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
To: Erik Rijkers <er(at)xs4all(dot)nl>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: proposal: option --application_name for psql
Date: 2013-05-14 19:25:00
Message-ID: CAFj8pRAzWB-fW+tuceE1fp+fkPH-evnjbHnWQrc8e_U00NfgUQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

2013/5/14 Erik Rijkers <er(at)xs4all(dot)nl>:
> On Tue, May 14, 2013 21:04, Pavel Stehule wrote:
>> Hello
>>
>> we like to use psql in combination with bash - just like postgresql driver.
>>
>> Actually there is no simple possibility (from command line) to set
>> application_name. We would to use different name than psql - for
>> example "splunk", ...
>>
>> I tested PGAPPNAME, but it doesn't work.
>>
>
> It does work:
>
> $ PGAPPNAME=splunk psql -c "select application_name from pg_stat_activity;"
> application_name
> ------------------
> splunk
> (1 row)
>
> But perhaps I misunderstood your intention?
>

I was wrong - PGAPPNAME works, thank you

but command line --application_name option should be a useful option I
am thinking still

Regards

Pavel

>
> Thanks,
>
> Erik Rijkers
>
>
>
>

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Magnus Hagander 2013-05-14 19:33:54 Re: proposal: option --application_name for psql
Previous Message Erik Rijkers 2013-05-14 19:18:41 Re: proposal: option --application_name for psql