External validation and validation rules
External validation is a common service that validates data in the back-end, as XML. It determines whether the data being entered by users is valid for your particular implementation of the product. The data is validated according to the validation rules and functions that you configure and extend to suit your requirements.
- Field level validation—Requires the investigation of only
one field and may include such criteria as:
- whether the field is optional or mandatory
- field domain type: for example, a string, an integer, or others
- minimum and maximum field lengths and values
- allowable and prohibited values and patterns.
- Cross-field level validation—Requires the investigation of two or more fields.
- Group Validation Rules—Consist of InfoSphere® MDM business objects such as ContactPartyRole.
- Element Validation Rules—Consist of attributes within an object, such as StartDate.
All of these validation components—groups, elements, and their related parameters—are defined in database tables external to the InfoSphere MDM code. When you add or edit group validations and their parameters in the Administration application, you are modifying the V_GROUP_VAL and V_GROUP_PARAM database tables. Likewise, when you add or edit element validations and their parameters, you are modifying the V_ELEMENT_VAL and V_ELEMENT_PARAM database tables.
Typically, before updating or adding a transaction with end-user data, you must validate the existing data fields to confirm that they contain suitable values. This validation can be simple or complex, depending on the nature of the data that needs to be processed. For example, with a mandatory gender field, a simple external validation could check that the field contains a value and that the value is either "M" or "F". A more complicated example of validation might include a party that has a certain role on a contract and must contain specific values, such as date of birth and gender. The validation would check these values before allowing the role to be added to the database.
All the necessary metadata, functions, and sample validations necessary for using the external validation feature are loaded as part of the InfoSphere MDM installation. However, before proper data validation can take place, you must configure both group and element validation rules to meet the specific requirements of your system.
For more information on data validation, refer to the developer topics for information on Validating Data.
By creating a new group validation rule, you are defining rule parameters that you link to anInfoSphere MDM business object, such as Contract, PartyAddress, or OrganizationName, that determine how end-user data from that business object is validated.
While group validation rules determine how end-user data from InfoSphere MDM business objects is validated, element validation rules determine how individual elements of those business objects are validated. For example, the mandatory element ZIPPostalCode could belong to the business object Address. A validation rule for this element would check that a ZIP or postal code was entered and, if not, would return an error message to the user.