hi!

most probably the reason of your problem is that strings are not properly
taken care of in your program.
Modify the line <OPTION value=<%=d%> <%=sel%>> <%=dd%> as follows:

<OPTION value='<%=d%>' <%=sel%>> <%=dd%>

Because the variable d may conatin strings with spaces.
Hope this helps.

Regards,
Sandeep



Disclaimer:
This document is intended for transmission to the named recipient only.  If
you are not that person, you should note that legal rights reside in this
document and you are not authorized to access, read, disclose, copy, use or
otherwise deal with it and any such actions are prohibited and may be
unlawful. The views expressed in this document are not necessarily those of
HCL Technologies Ltd. Notice is hereby given that no representation,
contract or other binding obligation shall be created by this e-mail, which
must be interpreted accordingly. Any representations, contractual rights or
obligations shall be separately communicated in writing and signed in the
original by a duly authorized officer of the relevant company.




-----Original Message-----
From: Vaishali S. Pandya [  <mailto:[EMAIL PROTECTED]>
mailto:[EMAIL PROTECTED]]
Sent: Friday, June 28, 2002 10:19 AM
Subject: mending-error 500


i can't understand this error
u know what?
my jsp was running very nicely and suddenly it did stop to work
i fill a select with my dept_master
the rs fetches some rows and then give me this mending error -500 and
terminate the program
plus not on perticuler row, every time it fetches random no of rows like 5,
10, 12 or n and just stop
no error is there in my code i think
here it is


<SELECT <%=dis%>  style="width=100%" name=dept tabindex=47>
<OPTION>
</OPTION>
<%
cmd="select * from hrm_dept_master order by dpt_dept_name";
rs1=stmt.executeQuery(cmd);
rs1=stmt.executeQuery(cmd);
while(rs1.next()){
      String d=rs1.getString(1);
      String dd=rs1.getString(2);
      if (d.equals(jdept)){
            sel="selected";
      }
      else{
            sel="";
      }
      %>
      <OPTION value=<%=d%> <%=sel%>> <%=dd%>
      <%
}
rs1.close();

pls can any one help?
Regards
Vaishali
Reliance Ind Ltd
A'bad

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://archives.java.sun.com/jsp-interest.html
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.jsp
 http://www.jguru.com/faq/index.jsp
 http://www.jspinsider.com

Reply via email to