My customers will use this application to build and change data. My inProgressRequestCode is a Request Code Unit class in my bean.
private RequestCodeUnit inProgressRequestCode;
The class contains variables for the data elements that make up a request code, such as priority number. We store each request code as a row in DB2.
I have a validator class, RequestCodeValidator, that I registered in faces-config.xml.
Here is my problem:
When we wish to change data for a request code, I read the appropriate row from DB2 and populate the variable fields in inProgressRequestCode. If requestCodeBean.inProgressRequestCode.priorityNumber contains one of the values listed in the selectOneMenu, all is well. My validator is invoked successfully. Unfortunately, we may have bad data in DB2. For example, if requestCodeBean.inProgressRequestCode.priorityNumber contains �3�, JSF writes a message like this to the console and prevents my validator from getting control:
[4/16/08 15:34:15:309 CDT] 00000027 jsf E com.sun.faces.context.FacesContextImpl addMessage Adding Message[sourceId=form1: priorityMenu,summary=Validation Error: Value is not valid)
JSF throws the �Validation Error: Value is not valid� message into a message in the jsp: