We have postgres 9.5. My computer (Ubuntu 20.04) has pgadmin4 8.2, but when it connects to the 9.5 server I get this error:
column "wait_event_type" does not exist Line 10: wait_event_type || ': ' || wait event AS wait_event, ^
I was searching online & found that a change was made in postgres 9.6 that caused this error to occur in newer versions of pgadmin4.
When I try to downgrade to an older version of pgadmin4 I get this error:
$ sudo apt-get install pgadmin4=6.21
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
pgadmin4 : Depends: pgadmin4-server (= 6.21) but 8.2 is to be installed
Depends: pgadmin4-desktop (= 6.21) but 8.2 is to be installed
Depends: pgadmin4-web (= 6.21) but 8.2 is to be installed
E: Unable to correct problems, you have held broken packages.
Is there some way I could either downgrade pgadmin4, or install an older version alongside the current version?
I went on the pgadmin website but I couldn't find any information about older versions.
Simply specify all versions at once and it will work:
sudo apt-get install pgadmin4=6.21 pgadmin4-server=6.21 pgadmin4-desktop=6.21 pgadmin4-web=6.21
.APT doesn't like to consider downgrades when resolving dependencies. Therefore we need to manually specify all the versions when downgrading.
If it keeps annoying you when upgrading, you can do
sudo apt-mark hold pgadmin4 pgadmin4-server pgadmin4-desktop pgadmin4-web
. However, remember toapt-mark unhold
once the pgadmin bug is fixed so that you don't miss security updates.