PQstatus is getting blocked when database sytem powered off

From: "Sunil Khatri" <sunil(at)6dtech(dot)co(dot)in>
To: <pgsql-interfaces(at)postgresql(dot)org>
Subject: PQstatus is getting blocked when database sytem powered off
Date: 2008-07-22 15:48:32
Message-ID: 001901c8ec12$66ad2990$be00a8c0@6dBangalore.co.in
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces

Hi,
In my application I need to check connection status before executing the query. I am doing it using PQstatus.
Problem is : PQstatus is getting blocked If the system on which database server is running is powered off.
If I shutdown the database using pg_ctl stop or pkill -9 postmaster in that case its returning.

Is there any other way to check the connection status in this case?

Thanks
Sk

Responses

Browse pgsql-interfaces by date

  From Date Subject
Next Message Tom Lane 2008-07-22 17:28:46 Re: PQstatus is getting blocked when database sytem powered off
Previous Message Sunil Khatri 2008-07-22 15:41:13 PQstatus is not returning