Hello all,
Could some one please explain why my program cant find the jdbc driver for my mysql database I have configured it according to the ubuntu website, it looks like other people have had a similar problem until the defined their drivers in their classpath. But I still get the same error no class defined errors:
install jdbc:
Code:
sudo aptitude install libmysql-java
export the classpath:
Code:
export CLASSPATH=$CLASSPATH:/home/adrian/Desktop/mysql-connector-java-5.1.5. tar.gz:/usr/share/java/mysql-connector-java.jar:/usr/share/java/mysql.jar:/u sr/share/java/jtds-1.2.2.jar
Application code:
Code:
dbDriver = "com.mysql.jdbc.Driver";
dbUrl = "jdbc:mysql://localhost/helpdesk";
Error message:
Code:
Error with SQL: java.sql.SQLException: No suitable driver found for jdbc:mysql://localhost/helpdesk.
Could someone please help with this, thanks trscookie.