i have a problem in JDBC every thing is ok it shows this messagejava.lang.ClassNotFoundException: sun.jdbc.odbc.JdbcOdbcDriver
i already create DSN but but it stil show this error i do not know what i do
My jdk is 64 bit and i create DSN of odbc 32 bit is any problem is here that jdk is 64 bit and odbc is 32 bit
my code is here
import java.sql.*;
class FirstJDBC{
public static void main(String s[]){
try{
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
String url="jdbc:odbc:personDSN";
Connection con=DriverManager.getConnection(url);
Statement st=con.createStatement();
String q="SELECT * FROM Person";
ResultSet rs=st.executeQuery(q);
while(rs.next()){
String name=rs.getString("name");
String add=rs.getString("address");
String pNum=rs.getString("phoneNum");
}
con.close();
}catch(Exception e){
System.out.println(e);
}
}
}
please help me