For example: Data type validation is customarily carried out on one or more simple data fields.The simplest kind of data type validation verifies that the individual characters provided through user input are consistent with the expected characters of one or more known primitive data types; as defined in a programming language or data storage and retrieval mechanism as well as the specification of the following primitive data types: 1) integer; 2) float (decimal); or 3) string.For example the delivery date cannot be before the order date.
An e-mail address might require at least one @ sign and various other structural details.
Regular expressions are effective ways of implementing such checks.
The rules may be implemented through the automated facilities of a data dictionary, Data validation is intended to provide certain well-defined guarantees for fitness, accuracy, and consistency for any of various kinds of user input into an application or automated system.
Data validation rules can be defined and designed using any of various methodologies, and be deployed in any of various contexts.
For example a numeric field may only allow the digits 0–9, the decimal point and perhaps a minus sign or commas.
A text field such as a personal name might disallow characters such a markup-based security attack.
The Post-validation action sends feedback to help enforce validation.
Simple range and constraint validation may examine user input for consistency with a minimum/maximum range, or consistency with a test for evaluating a sequence of characters, such as one or more tests against regular expressions.
A validation process involves two distinct steps: (a) Validation Check and (b) Post-Check action.
The check step uses one or more computational rules (see section below) to determine if the data is valid.
For example, many database systems allow the specification of the following l (plus, minus, and parentheses).