I have access to a remote postgres DB from pgAdmin4 and I also could access from nodejs using a Mac. Right now I\'m using the same code to access the DB in Windows. The code for
I suspect that you have the same problem like in this other post. Since it is not a 100% duplicate I will post this again:
There is a known issue in the pg module and NodeJS 14.
The proposed solution is to make sure you have pg>=8.0.3
installed.
This can be done by updating pg
in the dependencies.
Also make sure, that any other library depending on the pg
module, is also up to date and has the latest pg
version.
If this is not possible for any reason - using Node 12 should also work.