This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
hello I am trying to pass a ResultSet from an ActionClass into a JSP. But I would prefer not to use the request.setAttribute(). Is there a way someone can point me to research. I tied using the ActionForm but for some reason whenever I call it from the JSP it is null. I figured this was because I am not submitting a form to it. Any suggestions would be appreciated.
Did you have setResultSet() and getResultSet() with a private variable resultset in your ActionForm.
how did you set your resultset to the ActionForm? Did you use setResultSet() method.
If all above steps are done, then I guess you should be able to get the result by calling getResultSet() from your JSP.
Other solution would be to hold the resultset in session scope.
Hope this helps.
Joined: Aug 04, 2004
yeah there is a Getter and Setter, I pass it to the form as a Collection of ValueObjects which all have getter and setter methods appended to them. When I send it in the request.getParameter() it sees it fine, and I can iterate through the Collection, but when I put the Collection inside the form it never comes through. I guess I will just keep it in the request.