Class.forName("oracle.jdbc.driver.OracleDriver").newInstance();
String url="jdbc:oracle:thin:@localhost:1521:orcl"; //orcl為數據庫的SID
String user="test";
String password="test";
Connection conn= DriverManager.getConnection(url,user,password);
String url="jdbc:oracle:thin:@localhost:1521:orcl"; //orcl為數據庫的SID
String user="test";
String password="test";
Connection conn= DriverManager.getConnection(url,user,password);
posted @ 2007-12-13 16:05 李鵬輝 閱讀(106) | 評論 (0) | 編輯 收藏