I bet you already know what a validation rule is, but let's discuss them again. A validation rule is a feature that is used to improve data quality. It is checked before a record is saved in the database.
They are defined by the following:
- A name
- An Active flag
- A condition (formula) that should trigger the error (a chain of conditions on fields of the object or related objects that triggers an error if evaluated as true)
- An error message that is displayed to the user
- A place where the error can be displayed
Here is an example of a validation rule:

Example of a simple validation rule
This validation rule prevents a user from inserting a negative value in the Invoice Amount field:

Validation rule triggers if its conditions are met
Some of its configuration fields are easy to understand:
- Error Message: Error displayed to the user if a condition is met. ...