I am trying to use a Java class that already worked great for me in the past in order to access MySQL from my JSP project, running Tomcat 6. The problem is, that this line:
con = DriverManager.getConnection("jdbc:mysql://localhost:3306/", "root", "password");
gives con a value of null.
Now, my question is - what can cause the "getConnection" method return null?
Edit: I see now that also, I get the infamous ClassNotFoundException: com.mysql.jdbc.Driver. I have the connector included in my build path. So why am I getting this error? And, does it have to do with getConnection returning null?