为什么提示"[ODBC 驱动程序 管理器] 未发现数据源名称并且未指定默认驱动程序"啊
import java.sql.*;
class DBConnectTest {
public static void main(String args[]) {
try{
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
String url="jdbc:odbc:sqlserver";
Connection connection=DriverManager.getConnection(url);
Statement statement = connection.createStatement();
String sql="SELECT * FROM test";
ResultSet rs = statement.executeQuery(sql);
String tt;
while (rs.next()) {
System.out.print("姓名:" + rs.getString("name"));
System.out.println(" 年龄:" + rs.getString("age"));
}
rs.close();
connection.close();
}
catch(Exception ex){
System.out.println(ex);
System.exit(0);
}
}
}