guys i m really havin hard time to establish connection bet jsp n mysql...give me some tips..i ve done all the procedures required for that n i couldn execute the followin code
<%@ page import="java.sql.*" %>
<%
String username="mahesh";
String password="mahesh";
String connectionURL = "jdbc:mysql://localhost:3306/mahesh";
Connection connection = null;
//Statement statement = null;
//ResultSet rs = null;
%>
<html><body>
<%
Class.forName("com.mysql.jdbc.Driver").newInstance();
connection = DriverManager.getConnection(connectionURL, username, password);
//statement = connection.createStatement();
out.println("connection established");
//rs = statement.executeQuery("SELECT * FROM cust2");
/*while (rs.next()) {
out.println(rs.getString("name")+"<br>");
}*/
//rs.close();
%>
</body></html>