I need some trivial help
In the following code, I am displaying a table on my jsp page. The first column on the table is APP_GROUP, which gets populated with Application names and in the same code I am converting the names in HTML links.
The problem I am facing is:
Lets say if I have an application name as: aaa
then I have to make a jsp page with name: aaa.jsp
with this approach I am getting stuck with the naming problem because, I need make use of aaa somewhere else as well.
what I want is some flexibility is creating these hyper links, something where I cant specify any link name ( not just aaa.jsp)
If there are 5 application names pulled up from the database, i should be able to specify links as:
Result sets should never be dealt with in a JSP page. Move your SQL code to a model Java class, extract the data from the result set as Java collections, close the result set, and forward to the JSP with the data in the collections.
Agreed. But apart from that, you seem to have a question which has nothing to do with SQL at all. You reference some mysterious "aaa" in your question. It's the name of your application? It's the name of a JSP page? Both? Why is it a problem?