Win a copy of Serverless Applications with Node.js this week in the NodeJS forum!
Forums Register Login
Hello Ranchers..
I'm doing JSP and oracle

in a new user registration form..
when the user registers a login name and password.. and submit..
the page will validate the username is already exists or not and
if it is exist it will redirect to the same page with a message
"The user already exist" and the fields for First name, Last name etc etc will be the same..

in the verification part..
i'm doing like this

String query = "Select username from system.erp_main where username='username' ";
ResultSet rs = stmt.executeQuery(query);
int i=0;
{String unameser = rs.getString(1);
{response.sendRedirect("validate_new_user.jsp?<%=fname=fname"%> ;

out.println("User validate successful!!");

so in the response.sendRedirect i want to put the parameters and then only i can display it in the text box of next page..

please help me ranchers.
is it possible to send the parameters with the command respons.sendRedirect
if so.. please help me "how to "

thanks in advance..
You could append them as query string parameters.
Alternatively, you could store them in session and read them back from the next JSP.
Another alternative would be to bind them to request scope and forward (using a request dispatcher) to the next page. They could then be read from request scope from the next page.
Acetylsalicylic acid is aspirin. This could be handy too:
global solutions you can do in your home or backyard

This thread has been viewed 660 times.

All times above are in ranch (not your local) time.
The current ranch time is
Apr 26, 2019 06:13:44.