rJava 'class not found' error with makeCluster

半世苍凉 提交于 2019-12-12 02:16:08

问题


I'm having this issue for a while now and can't find answers online. I try to execute makeCluster and somehow get this

Error in .jfindClass(as.character(driverClass)[1]) : class not found

library(doParallel)
library(foreach)
cores = makeCluster(2)
# Loading required package: methods
# Loading required package: DBI
# Loading required package: rJava
# Error in .jfindClass(as.character(driverClass)[1]) : class not found
# Calls: JDBC -> is.jnull -> .jfindClass
# Execution halted

Would anyone be able to help? Thanks.


回答1:


In your console first File-->changedir into your jar file location

then you try this one

drv <- JDBC(driverClass="com.mysql.jdbc.Driver", classPath="mysql-connector-java-5.1.23-bin.jar", identifier.quote="`")



来源:https://stackoverflow.com/questions/35451334/rjava-class-not-found-error-with-makecluster

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!