# \[BUG\] Error on Perspective and Named Queries with 3rd Party JDBC Driver

**URL:** <https://forum.inductiveautomation.com/t/bug-error-on-perspective-and-named-queries-with-3rd-party-jdbc-driver/20800>\
**Category:** Ignition Early Access\
**Created:** [November 13, 2018, 2:26pm UTC](https://forum.inductiveautomation.com/t/bug-error-on-perspective-and-named-queries-with-3rd-party-jdbc-driver/20800 "2018-11-13T14:26:21Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![krohnemannd](https://avatars.discourse-cdn.com/v4/letter/k/e95f7d/32.png) [@krohnemannd](https://forum.inductiveautomation.com/u/krohnemannd)\
**Post date:** [November 13, 2018, 2:26pm UTC](https://forum.inductiveautomation.com/t/bug-error-on-perspective-and-named-queries-with-3rd-party-jdbc-driver/20800/1 "2018-11-13T14:26:21Z")

</div>

Attempting to query to a 3rd party historian through their JDBC driver I ran into a few issues.

Running a named query or a perspective based system.db.runQuery against this driver yields this error:

GatewayException: sun.nio.ch.DirectBuffer.cleaner()Lsun/misc/Cleaner;  
caused by NoSuchMethodError: sun.nio.ch.DirectBuffer.cleaner()Lsun/misc/Cleaner;

Running a query within Vision, the Script Console, or the Database Query Browser yields the expected returned results, though I receive a HttpChannel warning in the gateway for the same error as above.

Within the Database Query Browser and Named Queries I also cannot browse through tables, which yields the error:

“GatewayException: Unable to read response from Gateway.  
caused by org.xml.sax.SAXParseException; lineNumber: 3; columnNumber: 11; The end-tag for element type “Response” must end with a ‘\>’ delimiter.”

I am leaning to this being a problem with the JDBC driver, but considering it will probably not be updated for Java 11 anytime soon, I am hopefully that it is not, or at least that I will be able to run queries within Perspective with the gateway warning as it seems like I can do in Vision. The driver claims it is compatible with Java 8-10.

Version: 8.0.0-beta0 (b2018111302)

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [November 13, 2018, 2:37pm UTC](https://forum.inductiveautomation.com/t/bug-error-on-perspective-and-named-queries-with-3rd-party-jdbc-driver/20800/2 "2018-11-13T14:37:41Z")

</div>

Hmm. Can you share the driver with us? Is it the PI JDBC driver?

---

<div class="post-metadata">

**Author:** ![krohnemannd](https://avatars.discourse-cdn.com/v4/letter/k/e95f7d/32.png) [@krohnemannd](https://forum.inductiveautomation.com/u/krohnemannd)\
**Post date:** [November 13, 2018, 2:45pm UTC](https://forum.inductiveautomation.com/t/bug-error-on-perspective-and-named-queries-with-3rd-party-jdbc-driver/20800/3 "2018-11-13T14:45:02Z")

</div>

That is is, the 2018 JDBC Driver.

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [November 13, 2018, 2:47pm UTC](https://forum.inductiveautomation.com/t/bug-error-on-perspective-and-named-queries-with-3rd-party-jdbc-driver/20800/4 "2018-11-13T14:47:05Z")

</div>

You might be able to work around this issue by installing your own Oracle JDK/JRE 11 on the gateway and then pointing `ignition.conf` at that instead of the embedded runtime.

It looks like the JDBC Driver didn’t quite get Java 9+ compatibility right.

---

<div class="post-metadata">

**Author:** ![krohnemannd](https://avatars.discourse-cdn.com/v4/letter/k/e95f7d/32.png) [@krohnemannd](https://forum.inductiveautomation.com/u/krohnemannd)\
**Post date:** [November 13, 2018, 3:01pm UTC](https://forum.inductiveautomation.com/t/bug-error-on-perspective-and-named-queries-with-3rd-party-jdbc-driver/20800/5 "2018-11-13T15:01:22Z")

</div>

That would be a shame, I wanted to get away from ever installing Java again. I will give it a shot and let you know how it works out.
