Search code examples
javarrjdbc

Which version of Java do I need for this


I'm trying to use R and the R package rjdbc to connect to an Oracle database. Unfortunately, due to my company's strict IT department, every step of the process is kinda complicated, allow me to explain:

  • For every bit of software we install, we need to get IT to do it for us, and only certain software versions are approved. I cant easily update them to newer versions
  • Our RStudio is version 1.3.1093
  • Our R is 4.1.2
  • We'll need to get Java installed, and I was tasked with figuring out which version of Java we should install. As far as I can tell, the version my company can easily install (without much barking up the food chain) is "Java 8".

So my question is: To connect to an Oracle database, with those versions of R and R studio, is Java 8 "fine"? Or will we have compatibility issues?


Solution

  • I feel your install and update pain. The rJava CRAN entry says:

    SystemRequirements: Java JDK 1.2 or higher (for JRI/REngine JDK 1.4 or higher), GNU make

    So pretty bare minimum version. I can vouch that I've used Java 8 to connect. In the rJava release notes, JDK-17 and 12 seem to have caused problems historically.

    The detail that has tripped up multiple of my colleagues is that you have to make sure you have the JDK installed. At our company only the JRE is installed by default on our laptops and people assume this satisfies the system requirement.