if you are using strictly
servlet, and the selection from the form goes from jsp -> servlet -> jsp, using the request parameters is usually ok.
since you want to have things selected,then go to another page, then come back to this page and have them selected again, storing on the session attribute is probably more helpful; otherwise you would have to implement the hidden fields on the second page to store the values, this is not a good thing to maintain.
i assume from having a select on each row of the table would mean you need to have dynamic / different names for each row (i.e. select_1, select_2).
I would then recommend making a bean, perhaps just an instance of a hashtable, and stuffing this onto the session attributes, and it will contain the state for all the select options on your screen.
this way
- there is only 1 session attribute to get for each list screen, the values of the hashtable key: the name of the select / combo box, value: the id of the selected option.
- if you have other table list screens that would possibly have different sets of selected things in the future, each of screen can can store the selected combobox values independently