mySQL的驱动程序
放到tomcat/bin下

解决方案 »

  1.   

    那个org文件夹和那个驱动jar文件都放进去了
    还是不行
    ClassNotFoundException
      

  2.   

    mysql的驱动要拷贝到/tomcat/common/lib里
      

  3.   

    ClassNotFoundException是因为
    select host, user from user结果集有空值
    while(rs.next()){
    out.print("<tr>");
    if(rs.getString("host")!=null)
    {  out.print("<td>"+rs.getString("host"));}
    if(rs.getString("user")!=null)
    {  out.print("<td>"+rs.getString("user"));}
    out.print("</tr>");
    }