Page 1 of 1

Set Application Name + PostgreSQL (SOLVED)

Posted: 05.01.2016, 20:14
by rrricci
Hello all.. Is there any way to set Application_Name when using PostgreSQL?

For exemple: When we connect to PostgreSql and run 'SELECT * FROM pg_stat_activity;' there is a field called application_name.. How to set it?

I know that with MSSQL it works..See: http://zeoslib.sourceforge.net/viewtopi ... it=appname

How about PostgreSql?

Thanks
Renato

Re: Set Application Name + PostgreSQL

Posted: 05.01.2016, 21:21
by miab3
ZConnection.Properties.Add('application_name=myapp1');

Michal

Re: Set Application Name + PostgreSQL

Posted: 06.01.2016, 12:31
by rrricci
Hi Michal.. Thanks for the help.. I added your suggestion on BeforeConnect and it worked!

Thank you!

Renato