Hello, I am confused on how to connect to a database through a java applet hosting on the server.
Within the applet I would use:
I assume user and password are just the values for the user I made for my database, but I don't know what to put in the URL parameter.
If anyone knows how this works the help is greatly appreciated.
Within the applet I would use:
Code:
try {
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); //Or any other driver
}
catch(Exception x){
System.out.println( "Unable to load the driver class!");
}
try{
Connection dbConnection=DriverManager.getConnection("url","user","password"); <-----------<
}
catch( SQLException x ){
System.out.println(x);
}
If anyone knows how this works the help is greatly appreciated.