Hello All,
I am having some difficulties in java while comparing between a variable and the next resultset. In my case, I want : if the temp variable = rs.next() then temp ="" else the rs.next() value should be displayed.
This is because I am getting the Tname field many times, so I would like to retrieve it once.
Here is my code
while(rs.next()){
%>
<tr>
<td width="238">
<%temp=rs.getString("TNAME");%>
<%=temp%> </td>
<td><%=rs.getString("ID")%></td>
<%
if (rs.next().equals(temp){
temp="";
}
}
rs.close();
%>