How to call Oracle stored procedure from Java?
I want to call one stored procedure from Java. I have written following code. But its not able to make connection to server where Database is running.
DriverManager.registerDriver (new oracle.jdbc.OracleDriver());
Connection conn = DriverManager.getConnection ("jdbc:oracle:thin:@192.168.100.148:1526:VIS1", "apps", "apps");
CallableStatement cstmt = null;
cstmt = conn.prepareCall("Begin myproc(:1); End;");
catch (SQLException ex)
System.out.println("Failed to establish a connection to: ");