Cannot establish database connection to PostgreSQL

I’trying to setup a datastore to PostgreSQL 10.10. Someone created an ODBC connection, which tests successfully with my credentials. However, when I create a datastore with the same credentials I get the following error:

'ODBC call to connect database failed with error: <ODBC call for data source <> failed: <FATAL: password authentication failed for user “user”
FATAL: password authentication failed for user “user”>

However, If I store the password in the ODBC connection itself (which you do not want to do) and leave it empty in the datastore definition, it all seems to be working fine. How come?
Any help would be highly appreciated.