Is it possible to connect to Base from Excel using VBA?

I have an existing spreadsheet set-up, but no need the db as well. The version of MS Office I have doesn’t have access so I would like to use Base and use the existing spreadsheet.

The excel needs to stay in place as it is for use by a few non-technical users.

Thanks.

Hi @Tim1, Have you found a solution to your problem? If one of the answers listed works for you, please mark it as correct. Otherwise, please give us more information so we may help you further. Thanks!

Ok - your question is coming at the problem all wrong - at least from the perspective of Base.

First Base is not a database program, it is a tool for building front ends for a database. It has included, unfortunately, a customized version of HSQLdb which allows the database data to be embedded in an ODB (OpenDocument Database Document) file.

When you do this, embed the database in the document, there is no way to access the data from outside of LibreOffice - there is no JDBC or ODBC connector available.

Instead, given what you want to do, you would create your database using some real database package - that could be the standalone version of HSQLdb or SQLite(though it has some issues with Base) or MySQL or Postgres…etc. You would then connect the Base font end to the database and the Excel spreadsheet to the same database using VBA.

Thank you. I am halfway to learning other frontends, and maybe will be able to do this soon (ish).

LibreOffice Base uses HSQL for its database engine. According to Wikipedia it has a JDBC driver so your best bet would be to try that. A quick search turned up several results indicating its JDBC implementation supports Java 1.6 and JDBC4,

HSQLDB is free open source software for which you can get commercial or community support. I would sugggest researching how Excel can connect to a HSQLDB using JDBC (most likely third-party software is involved). I lack the time to research this further, hopefully this will put you on the right track.

Well, if not the right track, at least it’s a track! Thank you. I shall post back if I find an answer.