• Post Reply Bookmark Topic Watch Topic
  • New Topic

Servlet JSP threw exception  RSS feed

 
Angus Price
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I am wondering if anyone can help me with this problem that I have not been able to duplicate. I have a recipe application form where the user types in there first name and last name etc. When I view the page both the first name and last name are visible. But, when I try to edit the page only the first name shows up and the last name field isn't populated.

Here is the log file response..

2004-09-10 08:16:47 StandardWrapperValve[jsp]: Servlet.service() for servlet jsp threw exception
org.apache.jasper.JasperException: getOutputStream() has already been called for this response
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 66144
144
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"JRT",

We're pleased to have you here with us on the Ranch, but there are a few rules that need to be followed, and one is that proper names are required. Please take a look at the JavaRanch Naming Policy and adjust your display name to match it.

In particular, your display name must be a first and a last name separated by a space character, and must not be obviously fictitious.

Thanks!
bear
Forum Bartender
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 66144
144
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
From the error message it looks like your code is doing something hinky and calling a combination of getOutputStream() and getWriter() perhaps? As you can see, doing so seriously gums up the works.

I think you need to re-evaluate how your code is emitting its output.
 
Angus Price
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I just wanted to post a reply as I figured out what my problem was..When the user typed their information into the form they would have a last name field "Smith" and a first name field "Mary". The information was concatinated and then submitted to the database as a single string "Mary Smith". If however the user's first name was "Mary Jo" and the last name "Smith" there would be a problem. When I would go to edit the information I still had two fields, but only one would populate and that would be the first name field with "Mary". Therefore I modified the edit form, so that a single string coming out of the database was populating a singe field called Name. Problem solved, yippy!

Hope this helps anyone with the same or a similar problem!
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!