Class.forName("com.microsoft.sqlserver.jdbc.ServerDriver"); String url="jdbc:sqlserver://localhost:1433;databaseName=ABC2015121029"; String user="sa"; String pass="1997520"; Connection con=null; Statement stmt=null; ResultSet rs=null; con=DriverManager.getConnection(url, user, pass); stmt=con.createStatement(); String sql="select * from 學生"; rs=stmt.executeQuery(sql);為什么連接不上數據庫
添加回答
舉報
0/150
提交
取消