Heya all,
I am having some issues and maybe someone has an answer for me!
I am trying to read write some *DBF table from a java application. I have found this code :
try
{
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
String connString="jdbc:odbc:Driver={Microsoft dBASE Driver *.dbf)};DefaultDir=C:\\test";//DefaultDir indicates the location of the db
Connection connection=DriverManager.getConnection(connString);
String sql="SELECT * FROM table_name where condition";// usual sql query
Statement stmt=connection.createStatement();
ResultSet resultSet=stmt.executeQuery(sql);
while(resultSet.next())
{
System.out.println();
}
System.out.println();
}
catch (ClassNotFoundException e)
{
e.printStackTrace();
}
catch (SQLException e)
{
e.printStackTrace();
}
This code is working fine with a 32-bit version of windows but when I try on 64 bit, it gives me the error :
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
I have looked it up and the best answer found was about something to do with playing with the DNs in system32 or sysWOW64 but I wasent able to get threw it or my understanding was no good enough....
Here is the link with that answer:
thanks in advance...