<identifier> expected Class.forName ("sun.jdbc.odbc.JdbcOdbcDriver");
843854Oct 16 2004 — edited Oct 18 2004hi
Really i don�t now which is the mistake in this program.
plis some one tell if the driver is bad, o java is bad instaling or yhe program is bad write.
the error message is:
<identifier> expected
Class.forName ("sun.jdbc.odbc.JdbcOdbcDriver");
^
1 error
Process completed.
and the program is:
public class Prueba {
String url = "jdbc:mySubprotocol:myDataSource";
Connection con = null;
Statement stmt;
Class.forName ("sun.jdbc.odbc.JdbcOdbcDriver");
String url = "jdbc:odbc:datos";
Connection con = DriverManager.getConnection(url, "", "");
public static void main(String[] args) {
// Create application frame.
PruebaFrame frame = new PruebaFrame();
// Show frame
frame.setVisible(true);
}
}