Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

drv issues while connection to snowfalke #42

Open
AdityaRon opened this issue Jul 22, 2021 · 0 comments
Open

drv issues while connection to snowfalke #42

AdityaRon opened this issue Jul 22, 2021 · 0 comments

Comments

@AdityaRon
Copy link

AdityaRon commented Jul 22, 2021

Here is the error I face while trying to connect to snowflake via R.

echo $JAVA_HOME /Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home

R CMD javareconf
Java interpreter : /Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/bin/java
Java version     : 1.8.0_202
Java home path   : /Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home
Java compiler    : /Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/bin/javac
Java headers gen.: /Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/bin/javah
Java archive tool: /Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/bin/jar

trying to compile and link a JNI program
detected JNI cpp flags    : -I$(JAVA_HOME)/include -I$(JAVA_HOME)/include/darwin
detected JNI linker flags : -L$(JAVA_HOME)/jre/lib/server -ljvm
clang -mmacosx-version-min=10.13 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/include -I/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/include/darwin  -I/usr/local/include   -fPIC  -Wall -g -O2  -c conftest.c -o conftest.o
clang -mmacosx-version-min=10.13 -dynamiclib -Wl,-headerpad_max_install_names -undefined dynamic_lookup -single_module -multiply_defined suppress -L/Library/Frameworks/R.framework/Resources/lib -L/usr/local/lib -o conftest.so conftest.o -L/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/server -ljvm -F/Library/Frameworks/R.framework/.. -framework R -Wl,-framework -Wl,CoreFoundation


I am running this on Mac OS. Ensured that JAVA home is set properly and rJava is successfully linked and installed.

JAVA_HOME        : /Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home
Java library path: $(JAVA_HOME)/jre/lib/server
JNI cpp flags    : -I$(JAVA_HOME)/include -I$(JAVA_HOME)/include/darwin
JNI linker flags : -L$(JAVA_HOME)/jre/lib/server -ljvm
Updating Java configuration in /Library/Frameworks/R.framework/Resources
Done.
library(RJDBC)
library(dplyr)
library(dplyr.snowflakedb)
options(dplyr.jdbc.classpath = "~/snowflake-jdbc-3.9.2-sources.jar")
my_db <- src_snowflakedb(user = "xxxx",
                         password = "xxxx",
                         account = "xxxx",
                         host = "xxxxxx.snowflakecomputing.com",
                         opts = list(warehouse = "xxxx",
                                     db = "xxxx",
                                     schema = "public",
                                     tracing = "on"))

URL: jdbc:snowflake://xxxxx.snowflakecomputing.com:443/?account=xxxxx&warehouse=xxxxxx&db=xxxx&schema=public&tracing=on
Error in (function (cond) :
error in evaluating the argument 'drv' in selecting a method for function 'dbConnect': java.lang.ClassNotFoundException

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant