楼主   我把oracle的jdbc加到了.../common/lib下
然后写了一个jsp
<%@ page contentType="text/html; charset=GB2312" import="java.sql.*" %>
<html>
<head>
<title>查询结果</title>
</head>
<body><%Connection Db=null;
Statement DataRequest=null;
ResultSet rs=null;
try
    {
    Class.forName("oracle.jdbc.driver.OracleDriver");
     Db=DriverManager.getConnection("jdbc:oracle:thin:@127.0.0.1:1521:huxb","system","system");
    }catch(ClassNotFoundException e){
        
        out.println("数据库没找到");
        out.println(e.toString());
    }
    catch(SQLException e){
        
        out.println("发生一个错误:"+
        e.toString());
    }
    
  String c="青山路口";  out.println("经过站点"+c+"的车有:");
    
        try{
            String query="SELECT b.bus_road FROM bus_b_stop b,bus_stop bb WHERE bb.b_stop='"+c+"' AND bb.s_no=b.s_no";
         DataRequest=Db.createStatement();
         rs=DataRequest.executeQuery(query);
        }
        catch(SQLException e){out.println("发生一个错误:"+
                e.toString());};
       boolean r=rs.next();
       if(!r){
          
           out.println("没找到请重新输入");       }
       else try{
           do{
               String a=rs.getString(1);
               out.println(a);
           } while(rs.next());
       }catch(SQLException e){out.println("发生一个错误:"+
                e.toString());}
       try{
           rs.close();
           DataRequest.close();
           Db.close();
       }catch(SQLException e){
           out.println("发生一个错误:"+e.toString());}%></body>
</html>但是运行出现了错误:
HTTP Status 500 - --------------------------------------------------------------------------------type Exception reportmessage description The server encountered an internal error () that prevented it from fulfilling this request.exception org.apache.jasper.JasperException
    org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:372)
    org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
    org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
root cause java.lang.NullPointerException
    org.apache.jsp.te_jsp._jspService(te_jsp.java:76)
    org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
    org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
    org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
note The full stack trace of the root cause is available in the Apache Tomcat/5.0.28 logs.
--------------------------------------------------------------------------------Apache Tomcat/5.0.28  
是不是要配置server.xml文件  怎么弄呢??