Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Passing a ResultSet from a servlet

 
Zein Nunna
Ranch Hand
Posts: 245
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Guys,

I was just curious, is it possible to send a ResultSet from a Servlet to a JSP? If so how is this done?

Thanks in advance

Zein
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Any java object can be bound to request, session, or context scope and read in a JSP.
People ususally process the resultset in the servlet or bean and pass a lighter, more generic object like a an arrayList or a plain old java array.

JSPs shouldn't need to import any of the java.sql packages.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic