You'll recognise my ignorance about but I need urgent help.
The java program below connects to oracle and retrievs the data. Yet, same piece of code within an applet cannot connect to the same db. Instead it receives the access denied (java.net.SocketPermission demo resolve) when calling getConnection. Do I need TOMCAT or something running for an applet to be able to connect to a db ?
System.out.println("Loading the driver");
Class.forName("oracle.jdbc.driver.OracleDriver");
System.out.println("Getting the connection");
conn = DriverManager.getConnection("jdbc
racle:thin
demo:1521:demo", "vuser1", "vuser1");
System.out.println("Creating the statement");
st = conn.createStatement();
System.out.println("Executing the query to find out number of projects");
rs = st.executeQuery("SELECT COUNT(rownum) FROM tr_request");
rs.next();
count = rs.getInt(1);
System.out.println("Entries = " + count);
If I need Tomcat or I am missing something can you please describe it in detail. Thanks
The java program below connects to oracle and retrievs the data. Yet, same piece of code within an applet cannot connect to the same db. Instead it receives the access denied (java.net.SocketPermission demo resolve) when calling getConnection. Do I need TOMCAT or something running for an applet to be able to connect to a db ?
System.out.println("Loading the driver");
Class.forName("oracle.jdbc.driver.OracleDriver");
System.out.println("Getting the connection");
conn = DriverManager.getConnection("jdbc
System.out.println("Creating the statement");
st = conn.createStatement();
System.out.println("Executing the query to find out number of projects");
rs = st.executeQuery("SELECT COUNT(rownum) FROM tr_request");
rs.next();
count = rs.getInt(1);
System.out.println("Entries = " + count);
If I need Tomcat or I am missing something can you please describe it in detail. Thanks