java odbc access 连接数据库失败

public class ConnectionPool {

private String jdbcDriver = "sun.jdbc.odbc.JdbcOdbcDriver";
private String dbPath = "";
private String dbUrl ="jdbc:odbc:driver={Microsoft Access Driver (*.mdb, *.accdb)};" +
        "DBQ=D:\\Workspaces\\MyEclipse 10\\test\\src\\org\\wuhang\\app\\db\\db1.mdb"; 
private String dbUsername = ""; 
private String dbPassword = ""; 
private String testTable = "cate";
private int initialConnections = 5; 
private int incrementalConnections = 5;   
private int maxConnections = 10; 
private Vector connections = null; 



    出现了
    Failed connecting to the Database!

2个回答

不用账号密码的吗? 先用数据库客户端登陆试试!

没有用户名和密码的吗

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问
相关内容推荐