I have promblem .I have variable that store store the attribute value of column .The colum has more then one value.How to i compare with javascript value .Currently I am using the following method .
<%String sql_query3 = "SELECT DISTINCT (ir_tran_typ),ir_rea_desc "+
" FROM intrcd "+
" GROUP BY ir_tran_typ ";
System.out.println("trans type"+sql_query3 );
try{
rset = db.execSQL(sql_query3);
}
catch(SQLException e) {
System.err.println("Error in query - intrcd - transaction_main.jsp " +e +" sql " +sql_query3);
}
while(rset.next()== true){
tran_cde = rset.getString("ir_tran_typ");
rea_desc = rset.getString("ir_rea_desc");%>
<%System.out.println("trans type 34 "+tran_cde );%>
//tran_typ = addElement('<%=tran_cde%>');
<% }%>
if(obj.value== '<%=tran_cde%>' ){
<% String sql_query2 = "SELECT ir_rea_cde,ir_rea_desc"+
" FROM intrcd"+
" WHERE ir_tran_typ = '"+tran_cde+"' " +
" ORDER BY ir_rea_cde ";
System.out.println("trans type"+ tran_cde);
try{
rset = db.execSQL(sql_query2);
}
catch(SQLException e) {
System.err.println("Error in query - emmast2 - transaction_main.jsp " +e +" sql " +sql_query2);
}
index = 1;
while(rset.next()== true){%>
document.all.rea_cde.options[<%=index%>] = new Option(eval('"<%=rset.getString("ir_rea_cde")%>"'));
document.all.rea_cde.options[<%=index%>].value = eval('"<%=rset.getString("ir_rea_cde")%>"');
document.all.rea_cde.options[<%=index%>].text = eval('"<%=rset.getString("ir_rea_desc")%>"');
<% index++;
}%>
}
}
please replay me soon
thank you.