3

Sometimes I leave a PgAdmin session alone for a while and when I come back to issue a query, I get an error

Server closed the connection unexpectedly. 
        This probably means the server terminated abnormally
        before or while processing the request.
******* Error **********

So, I know I just need to reconnect but it seems like I have to close the query window and reconnect and open a new query window for things to work.

Is it possible to reconnect and use the same query window?

It has been suggested that I click the execute button again after the error comes, and PgAdmin will reconnect the instance and execute the query. However, that does not work. PgAdmin is not reconnecting no matter how many times I try to re-execute.

0
2

If the connection you created has password saved in it, then just click the execute button again after the error comes. PgAdmin will reconnect the instance and execute the query. I am using pgAdmin 4.1.5 and that works for me. – Lohit Gupta

With newer versions, you just have to right click on server and select refresh, it should automatically re-connect to server if the password is saved – Murtuza Z

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.