700字范文,内容丰富有趣,生活中的好帮手!
700字范文 > firebird java_Firebird与java的连接

firebird java_Firebird与java的连接

时间:2018-10-24 08:25:23

相关推荐

firebird java_Firebird与java的连接

我在

Windows XP上安装了Firebird 2.1,并使用firebirdsql.jdbc-2.1.6驱动程序与java连接.码:

Class.forName("org.firebirdsql.jdbc.FBDriver");

connection = DriverManager.getConnection(

"jdbc:firebirdsql://localhost/3050//C:/firebird/database/EMPLOYEE.FDB",

"test","test");

我收到以下错误:

Caused by: org.firebirdsql.jdbc.FBSQLException: GDS Exception. 335544375.

unavailable database

Reason: unavailable database at

org.firebirdsql.jdbc.FBDataSource.getConnection(FBDataSource.java:122) at

org.firebirdsql.jdbc.FBDriver.connect(FBDriver.java:140) at

java.sql.DriverManager.getConnection(DriverManager.java:525) at

java.sql.DriverManager.getConnection(DriverManager.java:171)

请帮忙.

问题解决了:

实际上我有来自jar文件的问题

我从firebird官方网站下载了jaybird-full-2.1.6.jar,问题解决了.

正确的URL是

"jdbc:firebirdsql://localhost:3050/C:\\firebird\\database\\EMPLOYEE.FDB"

我之前也尝试过这个URL,但由于jar问题而无法正常工作.

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。