Hello all,
 
I have a JSP, that processes a form and is attempting to create a record in my database via CMP EJB (Person). After my form has been processed and the PersonHome.create() methods has succeeded (record has been created), the page tries to redirect to another JSP. But this doesn't work; instead i receive an exception:
 
java.lang.IllegalStateException: Response has already been committed, be sure not to write to the OutputStream or to trigger a commit due to any other action before calling this method.

at com.evermind[Orion/1.5.2 (build 10460)].server.http.EvermindHttpServletResponse.sendRedirect(Unknown Source)
at /department.jsp._jspService(/department.jsp.java:54) (JSP page line 19)
at com.orionserver[Orion/1.5.2 (build 10460)].http.OrionHttpJspPage.service(Unknown Source)
at com.evermind[Orion/1.5.2 (build 10460)]._ah._rad(Unknown Source)
at com.evermind[Orion/1.5.2 (build 10460)].server.http.JSPServlet.service(Unknown Source)
at com.evermind[Orion/1.5.2 (build 10460)]._cxb._abe(Unknown Source)
at com.evermind[Orion/1.5.2 (build 10460)]._cxb._uec(Unknown Source)
at com.evermind[Orion/1.5.2 (build 10460)]._io._twc(Unknown Source)
at com.evermind[Orion/1.5.2 (build 10460)]._io._gc(Unknown Source)
at com.evermind[Orion/1.5.2 (build 10460)]._if.run(Unknown Source)
without PersonHome.create() or response.sendRedirect() everything works fine (it works fine with either, but not with both).
What is going on? What am I doing wrong?

Reply via email to