Quantcast
Channel: Spring Community Forums - Data
Viewing all articles
Browse latest Browse all 297

how to Enter Data in Combo Box Dynamically from Database MySql in Spring MVC 3

$
0
0
My Jsp Form is

Code:

<form:form action="Imei.obj" modelAttribute="imei">
        <!-- to display error message from action method if any -->
        <form:select id="brand" path="brand">
            <form:option value="1">One</form:option>
        </form:select>
            <!--<input type="submit" value="Login" /><br />-->
</form:form>


myinsert code is :

Code:

                           
                String sql = "insert into imei(brand_name,model_number,imeiNo,date_added)"+"values(?,?,?,?)";
                        jdbcTemplate.update(sql, new Object[] { imei.getBrandName(),imei.getModelNo(),imei.getImeiNo(),imei.getAddedDate()});

Please Tell me how to retrieve data from database and show in Combo Box in Jsp page

Viewing all articles
Browse latest Browse all 297

Trending Articles