Something like:
<%! ResultSet rset; %>
//logic to get a result set of names from database
<select name="employees">
<%
if (rset!=null) {
while(rset.next()) {
%>
<option value="<%= rset.getString("EmployeeID") %>"><%=
rset.getString("FirstName") + " " + rset.getString("LastName") %></option>
<% }
}
%>
</select>
>>> [EMAIL PROTECTED] 8/2/00 4:30 >>>
Hi,
I need to be able to retrieve a list of employees' names from Oracle and
populate a list box with that data.
Retrieving the names and displaying them on a webpage as plain text is fine
. I am just not clear how to dynamically populate a list box so that the
user may select one and then I can use the selected value to retrieve that
employee's information.
Can anyone point me in the right direction?
Regards,
Eoin.
~
"Ní hé lá na gaoithe lá na scolb"
T: +353 1 6710692
F: +353 1 6710863
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets