[英]can we use jdbc if vendor has not provided driver?
This is just a theoretical question for my own knowledge. 这只是我自己知识的理论问题。 Most of the RDBMS databases that we use have vendor provided JDBC driver but if there is a DB for which vendor has not provided any driver, is it still possible to connect to that database using JDBC?
我们使用的大多数RDBMS数据库都有供应商提供的JDBC驱动程序,但是如果有供应商没有提供任何驱动程序的数据库,是否仍然可以使用JDBC连接到该数据库? Does that mean that we will have to write our own driver or is there any other way?
这是否意味着我们必须编写自己的驱动程序或者还有其他方法吗?
As Jan pointed out, there's a JDBC-ODBC Bridge
that allows you to write JDBC code provided that there's an ODBC driver for the database, if for some reason there doesn't exist a JDBC driver for the database. 正如Jan所指出的那样,如果由于某种原因不存在数据库的JDBC驱动程序,那么
JDBC-ODBC Bridge
允许您编写JDBC代码,前提是存在数据库的ODBC驱动程序。 I remember years ago it being very popular to connect to MS Access
, but even that's no longer the best way to go. 我记得几年前连接到
MS Access
非常受欢迎,但即使这样也不再是最好的方式了。
However being in a situation where you don't have a JDBC driver should be very rare, and if you should encounter that kind of situation, maybe it would be a good time to migrate to a more modern database in any case.. 但是,在你没有JDBC驱动程序的情况下应该是非常罕见的,如果你遇到这种情况,也许在任何情况下迁移到更现代的数据库都是一个好时机。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.