[英]Testing UCanAccess with Oracle SQL Developer -> ODBC error
Quite exciting to find this jdbc driver for ms access. 很高兴找到这个用于ms访问的jdbc驱动程序。
However, when I try to test it with Oracle SQL Developer, I got: 但是,当我尝试使用Oracle SQL Developer进行测试时,我得到了:
Status : Failure -Test failed: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
状态:失败-测试失败:[Microsoft] [ODBC驱动程序管理器]找不到数据源名称,未指定默认驱动程序
Quoted from UCanAccess website: 从UCanAccess网站引用:
Because it is a pure java implementation it run in both Windows and non-Windows Operative Systems(eg, linux/unix).
由于它是纯Java实现,因此可以在Windows和非Windows Operative系统(例如linux / unix)中运行。 No ODBC needed.
无需ODBC。
What am I missing? 我想念什么? Or I must configure ODBC in Windows environment?
还是我必须在Windows环境中配置ODBC?
You shouldn't be using an ODBC URL, to open a hypothetical test.mdb in the user's home directory you might use something like 您不应该使用ODBC URL, 而是要在用户的主目录中打开假设的test.mdb ,
File file = new File(System.getProperty("user.home"), "test.mdb");
Connection conn = DriverManager.getConnection("jdbc:ucanaccess://" +
file.getPath());
The JDBC url begins with jdbc:ucanaccess://
which is followed by the Access database file path. JDBC网址以
jdbc:ucanaccess://
开头,后跟Access数据库文件路径。
Finally, make sure you have the required dependencies (which are documented as) 最后,确保您具有必需的依赖项(记录为)
jackcess-2.0.0.jar or later
jackcess-2.0.0.jar或更高版本
- commons-lang-2.4.jar
公地郎2.4.jar
- commons-logging-1.0.4.jar
共享记录-1.0.4.jar
hsqldb.jar(2.2.5)
的hsqldb.jar(2.2.5)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.