i have created a code which takes username pass etc from the user and then pts them in the database which is made using MSaccess the program complies very well but when i open my database no entries have been entered in there can u plz help
<%@page contentType="text/html"%>
<%@page pageEncoding="UTF-8"%>
<%@ page language="java" import="java.sql.*;" %>
<%
Connection conn = null;
PreparedStatement pstmt = null;
%>
<%
String firstname = request.getParameter("yourname");
String lastname = request.getParameter("endname");
String UserId = request.getParameter("Rexmail Id:");
String Password = request.getParameter("Password");
String Password1 = request.getParameter("Re-type Password");
String Answer = request.getParameter("Security Question");
String Answer1 = request.getParameter("Your Answer");
try {
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
conn = DriverManager.getConnection("jdbc:odbc:pubs1");
pstmt = conn.prepareStatement(" INSERT into books (firstname,lastname,id,pass,repass,que,ans) VALUES (?,?,?,?,?,?,?);");
pstmt.setString(1, firstname);
pstmt.setString(2, lastname);
pstmt.setString(3, UserId);
pstmt.setString(4, Password);
pstmt.setString(5, Password1);
pstmt.setString(6, Answer);
pstmt.setString(7, Answer1);
pstmt.executeUpdate();
pstmt.close();
out.println("account created");
}
catch(Exception e) {
out.println("Error.."+e);
}
%>