Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.2k views
in Technique[技术] by (71.8m points)

oracle - no ocijdbc9 in java.library.path

When I try to run Java application, I receive the following error:

Exception in thread "main" java.lang.UnsatisfiedLinkError: no ocijdbc9 in java.library.path

I don't have a file ocijdbc9.* on my PC, but I have ocijdbc10.dll in %ORACLE_HOME%in.

%ORACLE_HOME% is correctly specified, so I think the problem is that the application is searching for the wrong version (9 instead of 10).

Both Oracle and Java Builder are freshly installed, so the problem may be in project preferences? Do you have any ideas on how to search for the place where the wrong version is specified?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

You're missing a file from your java CLASSPATH.

You need to add the OCI jar to your classpath.

For my oracle 10.0.2 install on windows it's located in

%ORACLE_HOME%jdbclibojdbc14.jar

If your application requires ocijdbc9 then you'll have to download it from somewhere and add it to the CLASSPATH. I don't know where to download it from, try the oracle site


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...