How to modify SQL information into specific models, eg dropdownlists

    General discussion

  • Hello,

    We are using ms sql atm and we have successfully established a JDBC connecting, between our database and frontend on HTML/JSP We have also successfully retrieved column information but cannot model it into any other form. We are using NetBeans to establish the connection. If anyone could help insert the information into a drop-down menu we woudl be greatful. The following is what we have and what we have been trying.

    <%@taglib prefix="c" uri=""%>
    <%@taglib prefix="sql" uri=""%>
    <%@page contentType="text/html" pageEncoding="UTF-8"%>

            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
            <title>JSP Page</title>
            <table id="table1">
                <input type="text" id="textbox1" value="">
            <input type="submit" id="buttonz" onclick="hoping">
        <sql:query var="result" dataSource="jdbc/Test">
            FROM ERIT
        <table border="1">
            <!-- column headers -->
            <c:forEach var="columnName" items="${result.columnNames}">
                <th><c:out value="${columnName}"/></th>
        <!-- column data -->
        <c:forEach var="row" items="${result.rowsByIndex}">
            <c:forEach var="column" items="${row}">
                <td><c:out value="${column}"/></td>

    • Edited by AZeBuilder Thursday, April 19, 2012 7:35 AM
    • Changed type Papy NormandModerator Thursday, April 26, 2012 5:22 PM not related to SQL Server Data Access
    Thursday, April 19, 2012 7:18 AM

All replies

  • I am sorry to tell you that this forum is not suitable for this question though your question is related to sql server somewhere. It says this forum is for data access to SQL Server using SQL Native Client, OLEDB, ODBC, ADO, WDAC/MDAC, JDBC, or SOAP/HTTP.. But your question is more about web page. It's better to ask it in a jsp forum or forum. More related professors there will miss this related questions if it posted in this forum. 


    Monday, April 23, 2012 7:13 AM