public static void main(String[] args) {
    String url = "jdbc:mysql://172.16.27.11:3306/jdbcTest";
    String user = "mysql";
    String password = "mysql";
    String driverName = "com.mysql.jdbc.Driver";
    
    try {
        Class.forName(driverName);
        Connection conn = DriverManager.getConnection(url, user, password);
        Statement s = conn.createStatement();
    } catch (ClassNotFoundException e) {
        e.printStackTrace();
    } catch (SQLException e) {
        e.printStackTrace();
    }
    
}

 

JDBC源码分析(加载过程)

 

相关文章:

  • 2021-12-05
  • 2021-12-11
  • 2021-09-02
  • 2021-11-24
  • 2021-06-23
  • 2021-04-24
  • 2021-05-26
猜你喜欢
  • 2022-01-17
  • 2021-07-25
  • 2022-12-23
  • 2021-06-21
  • 2021-08-23
  • 2021-08-31
相关资源
相似解决方案