Subject Re: [Firebird-Java] OpenOffice, Jaybird and Embedded Server
Author Mark Rotteveel
On 13-12-2011 14:39, certfb wrote:
> I would like to use the Firebird embedded server within OpenOffice / LibreOffice as an alternative to using the internal database. This is because I feel more comfortable with the Firebird's SQL dialect and the multiple advantages of Firebird over other engines.

Why do you want to use embedded, and not just install Firebird server?

> Currently I am using Windows Vista.
>
> I have followed the general installation instructions for Firebird embedded that are here http://www.firebirdsql.org/manual/ufb-cs-embedded.html and also the information here http://www.firebirdfaq.org/faq350/
>
> So currently I have a folder D:\Databases which has all the Jaybird files and all the Firebird embedded files and ISQL.exe.
>
> I have created (and can still connect to) a database D:\Databases\TEST.FDB using ISQL, but cannot connect to it with OpenOffice (3.3.0).
>
> I have included D:\Databases\jaybird-full-2.2.0.jar in the CLASSPATH (Tools->Options-Java) and set the start parameters for the JRE as -Djava.library.path=d:\Databases.
>
> I have set the environment variable FIREBIRD=D:\Databases
>
> The JDBC driver class is: org.firebirdsql.jdbc.FBDriver
> The datasource URL is: jdbc:firebirdsql:embedded:D/Databases/test.fdb
>
> When I try "Test Class" it tells me "The JDBC driver was loaded successfully."

When the driver is loaded, it only loads the Java side of things, so it
does not yet attempt to initialize the native libraries.

> When I try "Test Connection" it tells me:
>
> Error code: -1
>
> Failed to initilize Jaybird native library. This is most likley due to a failure to load the firebird client library.
>
> So my understanding from this is that Jaybird cannot find fbembed.dll (even though its in the same folder as the jar and the environment variable "FIREBIRD" is set to that folder")

The problem could also have to do with not having installed the right MS
Visual C DLLs installed.

I am not sure if it is actually possible to use embedded from
OpenOffice. I will see if I can get it to work (I am using LibreOffice
3.4 though.

--
Mark Rotteveel