I have a program here. I wonder if I can help you !!
<--
This is the a1.jsp page program.
-->
<Jsp: useBean id = "pool" scope = "page" class = "SQL _link. SQL _link"/> // reference the database connection bean
<Html>
<Head>
<Link rel = "stylesheet" type = "text/css" href = "main.css">
<Title> Untitled </title>
</Head>
<Body>
<Form name = f1 action = "a2.jsp" method = "post">
<Table>
<% ResultSet rs = null;
Int I = 0;
Rs = pool. Query ("select id, name, gender from database name ");
While (rs. next ())
{
I ++;
String tax = "ta" + String. valueOf (I );
String tbx = "tb" + String. valueOf (I );
String tcx = "tc" + String. valueOf (I );
%>
<Tr>
<Td>
<Input type = hidden name = "<% = tcx %>" value = "<% rs. getInt (1) %>">
<Input type = text name = "<% = tax %>" value = "<% = rs. getString (2) %>">
</Td>
<Td>
<Input type = text name = "<% = tbx %>" value = "<% = rs. getString (3) %>">
</Td>
</Tr>
<%
}
%>
<Input type = hidden name = hh value = "<% = I %>">
</Table>
</Form>
</Body>
</Html>
//------------------------------------------------------------------------------
// A2.jsp receives data from the a1.jsp page and saves it to the database !!
<Jsp: useBean id = "pool" scope = "page" class = "SQL _link. SQL _link"/> // reference the database connection bean
<Html>
<Head>
<Link rel = "stylesheet" type = "text/css" href = "main.css">
<Title> Untitled </title>
</Head>
<Body>
<%
Int key = integer. parseInt (request. getParameter ("hh "));
For (int I = 1; I <= key; I ++)