Cannot connect to *.dbf file through JDBC drivers

Posted by leodali on Stack Overflow See other posts from Stack Overflow or by leodali
Published on 2012-11-07T16:38:11Z Indexed on 2012/11/07 17:00 UTC
Read the original article Hit count: 340

Filed under:
|
|

i'm trying to connect to *.dbf (dBase III) file on my Java application, running on a Windows Server 2003 system. I'm encountering this error and I cannot really understand the meaning (sources for OdbcJdbc.java seems to be unavailable):

[Microsoft][ODBC dBase driver] '(unknown)' is not a valid path error

Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");

String database = "jdbc:odbc:DRIVER={Microsoft dBase Driver(*.dbf)};DBQ=D:\\dbNeri\\CARISTAT;";

Connection conn = DriverManager.getConnection(database);

Statement s = conn.createStatement();
String selTable = "SELECT * FROM CARISTAT";

Does it exists a JDBC driver able to connect to dBase files or do I have to import external libraries to do the magic?

Thanks in advance for your help!

© Stack Overflow or respective owner

Related posts about java

Related posts about jdbc