/ Published in: Java

Connecting to Oracle using Java JDBC
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
public class OracleJdbcTest { Connection con; public void init(FileInputStream fs) throws ClassNotFoundException, SQLException, FileNotFoundException, IOException { props.load(fs); Class.forName(driverClass); } { while (rs.next()) { // do the thing you do } rs.close(); ps.close(); } { OracleJdbcTest test = new OracleJdbcTest(); test.init(); test.fetch(); } }
Comments
