Hi all,
this is my program
i want insert the data from
jsp page when ever i am excuting the this i am getting following error
http://localhost:8082/ServletProject/sample.html is url the o/p is like following
Book Entry Form
Id: 1
Book Name:
java Author: weeee
submit -->button when i click on submit button i am getting following error
HTTP Status 500 -
--------------------------------------------------------------------------------
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 2 in the jsp file: /BookEntryForm.jsp
Generated
servlet error:
[javac] Compiling 1 source file
C:\Documents and Settings\admin\workspace\ServletProject\work\org\apache\jsp\BookEntryForm_jsp.java:54: ')' expected
An error occurred at line: 2 in the jsp file: /BookEntryForm.jsp
Generated servlet error:
String url=("jdbc

racle:thin:@localhost:1521:xe","system","remora");
^
An error occurred at line: 2 in the jsp file: /BookEntryForm.jsp
Generated servlet error:
C:\Documents and Settings\admin\workspace\ServletProject\work\org\apache\jsp\BookEntryForm_jsp.java:66: unclosed string literal
stmt.executeUpdate("insert into books_details(id,book_name,author) values('"+id+"','"+bookname+"','"+author+"');
^
An error occurred at line: 2 in the jsp file: /BookEntryForm.jsp
Generated servlet error:
C:\Documents and Settings\admin\workspace\ServletProject\work\org\apache\jsp\BookEntryForm_jsp.java:67: ')' expected
rst=stmt.executeQuery("select * from books_details");
^
An error occurred at line: -1 in the jsp file: null
Generated servlet error:
C:\Documents and Settings\admin\workspace\ServletProject\work\org\apache\jsp\BookEntryForm_jsp.java:112: 'catch' without 'try'
} catch (Throwable t) {
^
C:\Documents and Settings\admin\workspace\ServletProject\work\org\apache\jsp\BookEntryForm_jsp.java:31: 'try' without 'catch' or 'finally'
try {
^
C:\Documents and Settings\admin\workspace\ServletProject\work\org\apache\jsp\BookEntryForm_jsp.java:124: '}' expected
^
6 errors
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:83)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:315)
org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:406)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:463)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:442)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:430)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:511)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:274)
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:810)
note The full stack trace of the root cause is available in the Apache Tomcat/5.0.25 logs.
--------------------------------------------------------------------------------
Apache Tomcat/5.0.25
i know this is very big to check
but i am uable to excute the program properly
how can i resolve the problem
please any one help me in this program
[ April 10, 2008: Message edited by: Ulf Dittmer ]