Mar 21st, 2011, 05:01 AM
I would like to handle constraint violations, when the user delete a registry that is referenced by a foreign key.
What is the best way to do this. I would like to use something like "uncaughtException.jspx" but specific to this.
I guess this is very simple, but if anyone can help?
Mar 21st, 2011, 06:39 AM
Mar 21st, 2011, 08:38 AM
I am looking for something that does not include DAO, and that it's more Spring framework like.
I am trying something like this on webmvc-config.xml:
<bean class="org.springframework.web.servlet.handler.Sim pleMappingExceptionResolver" p:defaultErrorView="uncaughtException">
<prop key=".ConstraintViolationException">constraintViol ation</prop>
<prop key=".NoSuchRequestHandlingMethodException">resour ceNotFound</prop>
<prop key=".MissingServletRequestParameterException">res ourceNotFound</prop>
But the exception is not caught !!