<% String redirectURL = "http://whatever.com/myJSPFile.jsp"; response.sendRedirect(redirectURL);%>
This answer also contains a standard solution using only the jstl redirect tag:
<c:redirect url="/home.html"/>
Just define the target page in the action attribute of the <form> containing the submit button.
action
<form>
So, in page1.jsp:
page1.jsp
<form action="page2.jsp"> <input type="submit"></form>
Unrelated to the problem, a JSP is not the best place to do business stuff, if you need to do any. Consider learning servlets.