Error Eml.omshandshake Getparameter From Db .402
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up how to show database errors like constraints or any in web application as an alert or an error page up vote 0 down vote favorite 1 I have a page where am adding an employee into a table. In table i have set a composite key. If i insert same record through my application it throws error "HTTP Status 500 - PreparedStatementCallback; SQL [INSERT INTO EMPLOYEE_ROLE(EMP_NUM,ROLE,STATUS)VALUES (?,?,'LOGGEDIN')]; ORA-00001: unique constraint (EMPLOYEE_ROLE_PK) violated" My JSP page: Add New User Details <% System.out.println("your selected Emp_Num from script :"+request.getParameter("enum")+" "+request.getParameter("ename")); String eNum=request.getParameter("enum"); String eName=request.getParameter("ename"); if(eNum!=null){ System.out.println("your selected Emp_Num inside servlet:"+eNum); ArrayList
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up request.getParameter don't have null values when they are expected up vote 1 down vote favorite http://stackoverflow.com/questions/22398977/how-to-show-database-errors-like-constraints-or-any-in-web-application-as-an-ale I found this issue so perplexing (but also interesting) that I'd like to ask people here for insights. I've been teaching myself JSP and associated technologies. What I'm tring to do is to retrieve parameters from a JSP to a servlet, then use them with If( ). Here is part my coding. if ((request.getParameter("ID_A") != null || request.getParameter("Password_A") != null) && (request.getParameter("ID_B") != null || request.getParameter("Password_B") != null)) { errorMessage http://stackoverflow.com/questions/27913379/request-getparameter-dont-have-null-values-when-they-are-expected = "Information is detected for the both side"; request.setAttribute("errorMessage", errorMessage); request.getRequestDispatcher("4_enter_personal_info.jsp").forward(request, response); } // Other conditions... Here is part of a JSP(The previous step)
I'm tring to ensure that, when a client entered information on the both sides (For an existing customer/For a new customer), there will appear the above message "Information is detected for the both side" on a JSP. However, even if all the text boxes are blank, the error message appears. So all the request.getParameter( ) methods above don't contain null values even if I make them empty. Even if I can come up with other algorithms, I'd like to know the reason this phenomenon happens. Any advice will be appreciated. jsp servlets http-request-parameters share|improve this question edited Jan 13 '15 at 14:50 BalusC 683k20824732692 asked Jan 13 '15 at 0:57 YMD 339314 Related: stackoverflow.com/questions/7109419/… –BalusC Jan 13 '15 at 14:50 add a comment| 2 Answers 2 active oldest votes up vote 3 down vote accepted The reabe down. Please try the request again. Your cache administrator is webmaster. Generated Tue, 11 Oct 2016 11:47:23 GMT by s_wx1131 (squid/3.5.20)
be down. Please try the request again. Your cache administrator is webmaster. Generated Tue, 11 Oct 2016 11:47:27 GMT by s_wx1131 (squid/3.5.20)