Search code examples
postgresqlpsqldatagrip

Changes doing in psql shell doesn't show up in Datagrip session


I have user postgres with database postgres. I connected to it from Datagrip, but what I do in datagrip doesn't show when I do psql commands, same holds vice-versa.

I do sudo -su postgres psql and \c postgres

In Datagrip datasource parameters:

Host: localhost
Database: postgres
User: postgres
password: ******

Solution

  • You have to check the port from DataGrip as well as psql and make sure they are same.

    To check the port number from psql terminal run following SQL;

    SELECT *
    FROM pg_settings
    WHERE name = 'port';
    

    To check the port number of Datagrip, go to datasource configurations screen.

    enter image description here