dll missing in JDBC

后端 未结 9 912
Happy的楠姐
Happy的楠姐 2020-11-29 07:15

I am currently working with SQL in Java. Recently I got this error:

com.microsoft.sqlserver.jdbc.AuthenticationJNI 
WARNING: Failed to load the         


        
9条回答
  •  情深已故
    2020-11-29 08:08

    You have to make sure your DLL is in the classpath.

    One such way to do so is to put the path to the DLL in PATH environment variable.

    Other option is to add it to the VM arguments in the variable LD_LIBRARY_PATH, like this:

    java -Djava.library.path=/path/to/my/dll -cp /my/classpath/goes/here MainClass

提交回复
热议问题