String strNomDriverJDBC ="sun.jdbc.odbc.JdbcOdbcDriver";
try{ Class.forName(strNomDriverJDBC); }catch(ClassNotFoundException exception) {
exception.printStackTrace(); } try{
String strURL ="jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)};DBQ=My
Documents\\Essai.cdb";
Connection connection =
DriverManager.getConnection(strURL,"",""); }catch(SQLException exception) {
exception.printStackTrace(); }
|