Get invaluable Interview and Career Tips delivered directly to your inbox. Get your news alert set up today, Once you confirm your Email subscription, you will be able to download Job Inteview Questions Ebook . Please contact me if you there is any issue with the download.
Problem in connection with Oracle without ODBC using Think DriverFollowing code is not workinggiving error Exception in thread Main java.lang.NoClassDefFoundError:jdbc1import java.sql.*;class jdbc1 { public static void main(String args[]) { try{ Class.forName("oracle.jdbc.driver.OracleDriver"); Connection c=DriverManager.getConnection("jdbc:oracle:thin:@hostname:1521:sid","scott","tiger" ); Statement s=c.createStatement(); ResultSet rs=s.executeQuery("select * from books"); while(rs.next()) {System.out.println("dno="+rs.getString(1)+"t"+"dname="+rs.getString(2)+"t"+"loc="+rs.getString(3)); } }catch(Exception e){System.out.println(e);} } }
Related Answered Questions
Related Open Questions