I am able to connect with psql and do what I want, not in IntelliJ.
PostgreSQL version : postgres (PostgreSQL) 9.6.1
IntelliJ version : 2016.3.1
IntelliJ configuration :
URL : jdbc:postgresql://localhost:5432/sample
User : sample
Pwd : sample
Test connection : Successful
So, I connect (red square appears) and then try a simple query :
select 1;
And I got the error :
FATAL : role 'xxx' doesn't exist`
Why IntelliJ doesn't use the role specified in my configuration and want to use my personal login ?? Whatever I use as role, still got the same error.
Note: If I add my system username as role it works, but I would prefer to avoid that.