Access denied when trying to access MySql through connector J and Servlet
Posted on 2006-11-18
I am trying to connect to MySQL (most current version) db through a java servlet.
The error message I get is this: Error: java.sql.SQLException: Access denied for user ''@'localhost' (using password: NO)
The setup-driver string I am using is this:
The servlet runs under Tomcat (5), and the driver file is installed in the Tomcat directory under the shared/lib folder.
These settings work (allow access) when using MySQL from the command line, but also work using Navicat (GUI for M ySQL).
The intended use is for an expert system (Exsys Corvid) to be able to access the database on my local machine. We have it working fine on a remote internet hosting machine, but cannot get it working locally.
I know just enough about java etc to be dangerous!