PreparedStatement ps=connection.preparedStatement();
Object[] param={new User().getName(),new User().getPwd()};
for(int i=0;i<param.length;i++){
setObject(i+1,param[i]);
}
ps.executeQuery();//int i=ps.executeUpdate();
HttpSession session=request.getSession();
session.setAttribute("name",new User().getName);