Subject Re: [Firebird-Java] jdbc driver issue
Author Roman Rokytskyy
Hi,

> I have here a question regarding the connectivity of a database tool ( DbSchema ) with Firebird.
> We want to connect to Firebird using the jdbc driver.
> Therefore we load the JDBC driver dinamically using the Java URLClassloader.
> We do like this since the driver is loaded dinamically ( the drivers can be loaded during the execution of the application ).
> But when connecting we got the exception bellow. Could you help in fixing this issue ?
...
> java.lang.UnsatisfiedLinkError:
> no jaybird21 in java.library.path

This exception means that JDBC driver cannot find its JNI counterpart
(jaybirdXX.dll/libjaybirdXX.so), which should be somewhere in the
java.library.path (on Windows usually %PATH%, on Linux $LD_LIBRARY_PATH).

However, you need this only when you try to use the Type 2 or Embedded
mode. For the pure Java (Type 4) mode of operation you don't need the DLL.

This exception tells me that you JDBC URL is something like:

jdbc:firebirdsql:embedded:/path/to/db.fdb

or
jdbc:firebirdsql:local:/path/to/db.fdb
jdbc:firebirdsql:native:host/port:/path/to/db.fdb

Note, the Type 4 JDBC driver does not require such prefixes and has an
URL like this:

jdbc:firebirdsql:host/port:/path/to/db.fdb

Hope this helps.

Roman Rokytskyy