?? jdbc.java
字號(hào):
//package jdbctest;
import java.sql.*;
public class jdbc {
public static void main(String[] args) {
try{Class.forName("com.microsoft.jdbc.sqlserver.SQLServerDriver");
System.out.println("driver registed ");
Connection conn=DriverManager.getConnection
("jdbc:microsoft:sqlserver://localhost:1433;DatabaseName=School;User=sa;Password=8984427650");
System.out.print("conn succeed");
}
catch(Exception e2){e2.printStackTrace();System.out.println("failed");}
}
}
?? 快捷鍵說(shuō)明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -