Topic: Visual Age 3.5+Oracle817 JDBC driver Classes12.zip 环境应该怎样配置???

  Print this page

1.Visual Age 3.5+Oracle817 JDBC driver Classes12.zip 环境应该怎样配置??? Copy to clipboard
Posted by: kemble
Posted on: 2003-03-28 11:06

在Visual Age 3.5环境下:
Oracle817 JDBC driver Classes12.zip
编译失败! 为什么OracleDataSource找不到,说:“(1 of 2) The type named oracle.jdbc.pool.OracleDataSource is not defined”
请问,IDE环境应该怎样配置??程序如下:
import java.*;
import javax.*;
import oracle.jdbc.pool.OracleDataSource;

public class OracleTest {
public static Connection getConnection() {
OracleDataSource ods = null;
Connection conn = null;
try {
ods = new OracleDataSource();
ods.setDatabaseName("orcl");
ods.setDriverType("thin");
ods.setServerName("lxdev306");
ods.setUser("wsdemo");
ods.setPassword("wsdemo1");
ods.setPortNumber(1521);
conn = ods.getConnection();
}
catch (SQLException ex) {
ex.printStackTrace();
}finally{   return conn; }
}//end getConnection
}//end class definition


   Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent
Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1
客服电话 18559299278    客服信箱 714923@qq.com    客服QQ 714923