EJB design: Returning Resultset from ejb to jsp

  1. Returning Resultset from ejb to jsp (1 messages)

    Hi, In my jsp on some button click am calling a servlet and in the servlet am invoking an stateless ejb.In ejb a doing some business logic followed by database query which would return millions of records.Can I return resultset to jsp and show some small chunk of data initially say 1000 records and when user says next display next 1000 records in resultset.Can I close connection object once user closes jsp page?Any other alternative?

    Threaded Messages (1)

  2. Reply[ Go to top ]

    Consider using CachedRowSet implementation, its a disconnected rowset, so it will be leaner and easier to pass to JSP as compared to resultset..