Setting up custom settings
Since the beginning of my Salesforce career as a developer (a devmin actually, as I usually did both developer and administration tasks), it was clear that the Salesforce platform was missing an important part of building efficient and maintainable algorithms. It required a way to define some sort of variables (or placeholders of values) that could be referenced in formulas and whose values could be changed on the fly when needed, without the need to update the formula itself.
Let's perform the following practical example and take one of the validation rules we saw in Chapter 4, Cleaning Data with Validation Rules (based on the Opportunity object):
AND( OR( $User.Department != "Sales", $User.Division != "Big Customers" ), Amount > 500000 )
This checks whether the current user who is creating/updating an Opportunity is in the Sales
department...