Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2003
    Posts
    22

    Unanswered: Display 2 field of database in form <select>

    I have a database "code" with 2 field : "product_code" and "description".
    product_code | description
    PC | Personal Computer
    MS | Mouse
    etc

    The form will let user choose a product code from this database. The query is like this :

    java.sql.ResultSet rsproduct = statement10.executeQuery("SELECT * FROM code ORDER BY product_code");

    At the form section,

    <select name="product_code">
    <option value=""></option>
    <%
    while(rsproduct.next()){
    %>
    <option value="<%=rsproduct.getString("product_code").trim ()%>"><%=rsproduct.getString("product_code")%></option>
    <%}%>
    </select>

    How should I coding if wanna let user view the description for particular product_code while scroll down?

    Thanks~~

  2. #2
    Join Date
    Oct 2003
    Posts
    22
    Can any code for "pop up" the different description while the mouse pointer is on the different product_code?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •