Cannot register Calcite JDBC driver

Answered

I'm trying to use Apache Calcite JDBC driver in IDEA Ultimate 2020.2 but am failing to do so. I follow the same steps as described in https://intellij-support.jetbrains.com/hc/en-us/community/posts/207298565-Set-JDBC-Driver-Class?input_string=Cannot%20register%20Calcite%20JDBC%20driver and end up with the same issue: only default and incorrect "java.sql.Driver" option in Classes.

The correct driver class is org.apache.calcite.jdbc.Driver and I clearly see it in the used driver file (also attached for inspection: 2020_10_22_FK7Tb3euCwY3wUSm).

What am I missing?

4 comments
Comment actions Permalink

ANd what if you expand 'Class' list - will be there something else? are you sure this is proper JAR-file?

0
Comment actions Permalink

There's only single (default) item in the class list.

I've uploaded the jar file so you can potentially inspect it: 2020_10_22_FK7Tb3euCwY3wUSm

This is what I get when I inspect the jar:

davidkubecka@davidkubecka calcite % jar -tf core/build/libs/calcite-core-1.27.0-SNAPSHOT.jar|grep org.apache.calcite.jdbc.Driver
org/apache/calcite/jdbc/Driver$1.class
org/apache/calcite/jdbc/Driver$2.class
org/apache/calcite/jdbc/Driver.class

So I would say this is the correct jar file.

0
Comment actions Permalink

this driver inherits 'UnregisteredDriver' class which is not in this JAR, this is why it does not work.

0
Comment actions Permalink

Hm, I see. Will contact the Calcite driver maintainers. Sorry for bothering.

0

Please sign in to leave a comment.