Naveen..,
If there is any problem with sql import the error should come at the Connection
statement it self. Can u send me the sever log....?
Regards
Sreeni
naveen wrote:
> hi,
>
> I get "HTTP 500 - Internal server error "
> The page is not getting displayed.
>
> I looked up the temporary servlet formed in the work directory.
> but it does'nt seem to include the java.sql.* while importing.
>
> hence the below error is ocurring in the dos prompt(server log).
>
> work\%3A8080%2Fexamples\myappmain_jsp_1.java:56: Class
> C_0003a.javawebserver.jsw
> dk.examples.jsp.myapp.ResultSet not found.
> ResultSet rs=st.executeQuery("Select
> Name,ID,Place,Dgn from employee");
> ^
> how do i make the servlet formed include the java.sql .*..
> the import statement in the page tag is not getting recognised..
>
> any directions would be most helpful
>
> thanks
> naveen
>
> ----- Original Message -----
> From: Carsten Heyl <[EMAIL PROTECTED]>
> To: naveen <[EMAIL PROTECTED]>
> Cc: < >
> Sent: Wednesday, September 22, 1999 11:55 PM
> Subject: Re: dbaccess problem
>
> |
> | >hi,
> | >This might seem a bit trivial,but i am just not able to connect to a db
> | >i have set the classpath to tools.jar as well as jsdk.jar...
> | >JSP's code works fine except for recognising the sql related keywords..
> | >i know it has got to do with importing java.sql packages ,but it is not
> | >happening..
> |
> | So what DOES happen on your code below?
> | Compile time error?
> | Exceptions?
> |
> | >here is the code below...can anyone show me where the problem might be..
> | >thanks,
> | >naveen
> | >
> | ><HTML>
> | >
> | ><HEAD><TITLE>
> | >A JSP APPLICATION
> | ></TITLE></HEAD>
> | ><BODY BGCOLOR="white">
> | >
> | ><%out.println("it prints");%>
> | ><%@ page language="java" import="java.sql.*" %>
> | >
> | ><%
> | > Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
> | > Connection c =
> DriverManager.getConnection("jdbc:odbc:naveen","dba","sql");
> | > Statement st=c.createStatement();
> | > ResultSet rs=st.executeQuery("Select Name,ID,Place,Dgn from employee");
> | >
> | >%>
> | ><table>
> | > <% while(rs.next())
> | > { %>
> | > <tr>
> | > <td><%=rs.getInt("ID")%></td>
> | > <td><%=rs.getString("Name")%></td>
> | > <td><%=rs.getString("Place")%></td>
> | > <td><%=rs.getString("Dgn")%></td>
> | > </tr>
> | >
> | > <%}%>
> | > </table>
> | >
> | >
> | ></BODY>
> | ></HTML>
> | >
> |
> ===========================================================================
> | >To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> JSP-INTEREST"
> | .
> | >FAQs on JSP can be found at:
> | > http://java.sun.com/products/jsp/faq.html
> | > http://www.esperanto.org.nz/jsp/jspfaq.html
> |
> | Ciao,
> | Carsten Heyl
> |
> | Carsten Heyl [EMAIL PROTECTED]
> | NADS - Solutions on Nets http://www.nads.de/
> | NADS GmbH http://www.pixelboxx.de/
> | Hildebrandtstr. 4E Tel.: +49 211 933 02-90
> | D-40215 Duesseldorf Fax.: +49 211 933 02-93
>
> ===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
> FAQs on JSP can be found at:
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.html
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html