JSP-INTEREST�����ã�
when I use mm.mysql jdbc driver to connect ot mysql,
it can't connected successful.
The browers tell me the msg follow:
SQLException: Server configuration denies access to data source SQLState:���� 08001
VendorError:��0
I really don't know why.
Could you help me?
I use mysql-3.22.32 server and tomcat 3.1 and jdk 1.2.2 ,mm.mysql2.0.1 on redhat 6.1.
The test code is:
(ps: the connect accont can use bye mysql_client and other problem)
/********************************************************************/
<%@ page import="java.sql.*" %>
<%
try {
Class.forName("org.gjt.mm.mysql.Driver").newInstance();
}
catch (Exception E) {
out.println("Unable to load driver.");
}
try{
Connection C =
DriverManager.getConnection("jdbc:mysql://localhost/mysql?user=root&password=123456");
Statement s=C.createStatement();
ResultSet rs=s.executeQuery("select * from user");
rs.close();
s.close();
C.close();
}
catch (SQLException E) {
out.println("SQLException: " + E.getMessage());
}
%>
��
��
jsp_programmer
[EMAIL PROTECTED]
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets