标签:
try { Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver"); connection = DriverManager.getConnection( "jdbc:sqlserver://localhost:1433;databaseName=commentsys", "sa", "bequt"); } catch (Exception e) { // TODO Auto-generated catch block e.printStackTrace(); } System.out.println("Db连接数据库成功");
标签:
原文地址:http://www.cnblogs.com/bequt/p/5460143.html