Connecting to PostgreSQL database with LibreOffice Base

Hello,

I tried to resolve my problem with the information gathered on the internet, but I still don’t get why it is not working.

I am using LibreOffice 5.1.5 and PostgreSQL 9.4.

So in the Datasource URL I type:

dbname=geomatic_db hostaddr=192.168.1.112

Then I enter my login/password to test the connection. (The connection could not be established)

I can connect to my DB using PGAdmin or phppgadmin using the same credentials.

What am I doing wrong?

Haven’t used PostgreSQL in some time but I believe you are missing port=5432.

Still have the same error

Just downloaded, installed and connected. Used host=localhost port=5432 dbname=myTest

I’m on xubuntu 16.04 LO v5.2 and PostgreSQL 9.5

Still doesn’t work…

Where can I view logs of connection attempts? That would be useful for debug…

On Xubuntu it’s root/var/log/postgresql/postgresql-9.5-main.log

By the way, what connection type are you using. I’m using the default PostgreSQL connection installed with LO.

SDBC. I installed the Debian package libreoffice-sdbc-postgresql

But what about Base logs?

No Base logs. Why not use the native connector? Supposedly better than others. I don’t get it. I’ve completely installed twice today just to cover the bases. Used native connector in Base - no problems. Used JDBC in SQL Workbench also no problems. It’s pretty straightforward. I think MySQL was more difficult.

I purged LibreOffice* and reinstalled and it worked. I think the issue came from the fact that I installed LibreOffice from Debians’s backports but the SDBC driver from the Stable repo (i didn’t pay attention…). I installed everything from the same repo, and now it works.

Thank you!