private String dburl = "jdbc:mysql://localhost/ipcharge?user=root";try{
Class.forName("org.gjt.mm.mysql.Driver").newInstance();
Connection Conn = DriverManager.getConnection(dburl);
Statement Stmt = Conn.createStatement();
ResultSet RS = Stmt.executeQuery("SELECT * from ip_custom");
}catch (Exception E) {
JOptionPane.showMessageDialog(null, "不能载入MSql驱动程序!", "警告", JOptionPane.ERROR_MESSAGE);
System.exit(0);
}
Class.forName("org.gjt.mm.mysql.Driver").newInstance();
Connection Conn = DriverManager.getConnection(dburl);
Statement Stmt = Conn.createStatement();
ResultSet RS = Stmt.executeQuery("SELECT * from ip_custom");
}catch (Exception E) {
JOptionPane.showMessageDialog(null, "不能载入MSql驱动程序!", "警告", JOptionPane.ERROR_MESSAGE);
System.exit(0);
}
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货