Java:Oracle JDBC驅動程序返回錯誤 - 沒有合適的驅動程序問題描述 當我的Java應用程序登錄到Oracle 數據庫 中之後,DriverManager.getconnection失敗,Oracle JDBC驅動程序返回下面的錯誤信息: no suitable driver 為什麼會出現這個問題? 配置信息 操作系
Java:Oracle JDBC驅動程序返回錯誤 - 沒有合適的驅動程序問題描述
當我的Java應用程序登錄到Oracle
數據庫中之後,DriverManager.getconnection失敗,Oracle JDBC驅動程序返回下面的錯誤信息:
no suitable driver
為什麼會出現這個問題?
配置信息
操作系統 - HP-UX
版本 - 10.20
硬件系統 - HP9000
系列 - K420
應用程序 - Java c.010.07.00版和Oracle 7.3.4
解決方法
這個問題出現在Jbuilder為項目類打包時。Jbuilder為你配置應用程序,如果認為有必要,將包含所有的類。但是它無法知道動態裝載的類,而驅動程序必須要使用,因此驅動程序脫離配置。
解決方法就是在類路徑中包含Oracle提供的classes111.zip文件。
.........following with all English text ....
Problem Description
When my Java application logs into an Oracle database,
DriverManager.getconnection fails and the Oracle JDBC
driver returns this error message:
no suitable driver
What is causing this problem?
Configuration Info
Operating System - HP-UX
Version - 10.20
Hardware System - HP9000
Series - K420
Applications - Java version c.010.07.00 and Oracle 7.3.4
Solution
This problem o
clearcase/" target="_blank" >ccurs when JBuilder packages the classes for the project.
JBuilder deploys applications for you and includes all classes if thinks
are needed. But, it cannot know about classes that are loaded
dynamically, as the driver must be. So, the driver left out of the
deployment.
The solution is just to include in the classpath the classes111.zip
file provided by Oracle.