Hi Kashwini,
Firstly, when you are writing criteria.list(), collect it in a list instead of form object.
a. List<ProductForm> productFormList = criteria.list();
Going ahead if you are sure of receiving only one record, you can do a get(0) on the list as
b. ProductForm productForm = productFormList.get(0);
Next, you do not have to save it in session. On your JSP, you can directly iterate over productFormList (if you retrieve multiple rows), and display the values using <bean:write>, else directly use the form from line b. (if you are getting only one row), to display the values.
Hope this helps.
Thanks and Regards,
-------------------------------------------------------------------------------------
Komal Renu |
krenu@infocepts.com | www.infocepts.com
-------------------------------------------------------------------------------------