Skip to Main Content

SQL Developer

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Adding classpath to SQLDeveloper when using third-party jdbc driver (postgres)

Niels JespersenJul 1 2020 — edited Jul 8 2020

SQL Developer (I'm using 19.2.1) has a nice feature. It lets you connect to a third party database by specifying a jdbc-file. This works great with at least Postgres (using version 42.2.14 jdbc driver). Tools, Preferences, Database, Third-party Jdbc Driver, point to the relevant jar, and off you go.

However, I want to connect to Postgres with SSPI on Windows (using windows credentials). This requires the waffle-jna libraries. I can compile a java program and get it using SSPI via waffle-jna by setting classpath and then run the java program, like this:

set CLASSPATH=.;c:\waffle\postgresql-42.2.14.jar;c:\waffle\waffle-jna-1.9.1.jar;c:\waffle\jna-4.5.1.jar;c:\waffle\jna-platform-4.5.1.jar;c:\waffle\caffeine-2.6.2.jar;c:\waffle\jcl-over-slf4j-1.7.25.jar;c:\waffle\slf4j-api-1.7.25.jar

java jdbcpostgresdemosspi.Jdbcpostgresdemosspi

It works great. This example lndicates that it works as described in the documentation: If the server requests SSPI authentication, it will use waffle-jna if these libraries can be found on the classpath (which they can in my example).

But I would like to get SQL Developer to consider the waffle-jna libraries. So when SQL Developer calls into the Postgres JDBC driver and the server requests SSPI, it should be able to find the waffle-jna libraries on the classpath. But I cannot get this to work. Even if i set classpath before starting sqldevelper.

How, and if can I get this to work?

Thank you in advance.

Niels Jespersen

This post has been answered by Niels Jespersen on Jul 8 2020
Jump to Answer
Comments
Post Details
Added on Jul 1 2020
3 comments
2,026 views