problem with mysql 5.0 and java connector

W

wildsurfer

I've a strange message when I try to connect to my db using java
connector ( mysql-connector-java-3.1.4-beta ):

javax.servlet.ServletException: Cannot connect to MySQL server on
localhost:3306. Is there a MySQL server running on the machine/port
you are trying to connect to? (java.lang.NumberFormatException)

I'm using tomcat 5.0.
Note that i don't have any problem to connect to the sql server using
for example mysql front or querying the server directly.
before I was using mysql 4.0.13 and everything just worked fine!
I wanted to upgrade my mysql server to the newer version, but I don't
know how to fix this problem.
I suppose that I had to unistall the old version and install mysql
5.0, but it doesn't work any more!do i have to change something else?
why the jdbc connector doesn't work any more?

this is what I use to connect to my db (I'm using dreamweawer and this
is the connection file)

<%
// FileName="Connection_jdbc_conn.htm"
// Type="JDBC" ""
// DesigntimeType="JDBC"
// HTTP="true"
// Catalog=""
// Schema=""
String MM_top11_DRIVER = "org.gjt.mm.mysql.Driver";
String MM_top11_USERNAME = "root";
String MM_top11_PASSWORD = "";
String MM_top11_STRING = "jdbc:mysql://localhost:3306/mydb";
%>


Thank you very much
Andrea
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,042
Latest member
icassiem

Latest Threads

Top