Validation rule

A typical validation rule is a formula that determines what is to be included or excluded in a field. You can use standard Ability expressions to design the validation rule. The rule will then be compared with any data you attempt to enter into the field. If the data is allowed by the validation rule it will be accepted by the field; if not then the data will be refused and a validation text displayed (see Validation text).

Typical examples of validation rules are:

Note that the data elements in each of the formulas should be surrounded individually by quotes.

Since a validation rule determines what can be put into a field and will cause an appropriate message to be displayed if the rule is broken, it turns out that a blank field governed by a validation rule will be illegitimate and the validation text displayed as if the rule had been broken. Obviously there are cases where you will want fields to be left empty. To overcome this problem you should do the following:

For example, a validation rule might read:

= "Smith" OR "Jones" OR Is Null

which will allow "Smith", "Jones" or a blank field.

See:

Validation of data

Required property