Tuesday, March 27, 2001 09:52 AM
first thing is that u should get the values from the html page like this,
String name = request.getParameter("NAME");
String address = request.getParameter("ADDRESS");
here, NAME and ADDRESS are the name given in the html page.
then u write a query like this,
stmt.executeUpdate(" insert into test values('" + name + "', '" + address +"');
i think this whould work.
Monday, March 26, 2001 08:06 AM
I'm not very familiar with JSP ( being on the Microsoft side of the hedge at the moment ;-) ) , but I believe the statement
stmt.executeUpdate("insert into test values('name','address')");
should be replaced with
stmt.executeUpdate("insert into test values('" +
request.form('name') + "', '" +
or its equivalent in JSP