Examples
Formula Check examples
Choose a Formula example when the answer comes from fields on the record being checked or one of its parent records.
Use Verify with a formula when a Salesforce formula can return TRUE for a passing record and
FALSE for a record that needs attention. For example, require several Account fields, allow Phone
or Website, compare Number of Employees with a limit, or read a field from the parent Account.
If you have never created a Salesforce formula, begin with Create your first Check.
In formula syntax, functions such as ISBLANK() inspect values, NOT() reverses true and false,
and AND() or OR() combine conditions. The Formula reference covers the supported subset.
These pages are instructions; the installed package does not create these Checks. Follow an example to create a Check in Setup → Custom Metadata Types → Record Health Check → Manage Records.
Choose a Formula example
Section titled “Choose a Formula example”| Example | Salesforce question | What the example demonstrates |
|---|---|---|
| Seller research readiness | Does the Account have a Phone or Website? | Formula OR, optional alternatives, and an edit action |
| Billing address review | Are Billing City, Billing State, and Billing Country populated? | Formula AND with separate Found and Expected display formulas |
| Partner regional assignment | Does a Partner Account have the country needed for assignment? | Formula applicability, SKIPPED, and compact passed-Check display |
| Branch handoff | Does the parent Account contain the headquarters location? | Parent relationship fields and a parent-record action URL |
| Small-business program eligibility | Does Number of Employees meet the program minimum? | Numeric Formula comparison with Found and Expected always visible |
When Formula is the right choice
Section titled “When Formula is the right choice”Choose Formula when all required values are available from the current record or a parent relationship and the decision is clear in Salesforce formula syntax. A Formula Check cannot read a list of child records such as an Account’s Contacts. Use a Query example for child or other related records. Use an Apex example when the requirement needs custom calculations or must combine data from several Salesforce objects.
Every Formula Check needs:
| Setup field | What to enter |
|---|---|
| Evaluation Type | Verify with a formula |
| Pass Condition | A Salesforce formula that returns TRUE to pass and FALSE to fail |
| Applies To | All records, or an optional rule that produces SKIPPED when the Check does not apply |
Display: Found Formula and Display: Expected Formula are optional. They explain the result on the card but do not decide whether the record passes, and they resolve their own return type, so Formula Result Type does not apply to them. Set that field for the formula the Check calculates with, and leave it on Automatic if you are unsure.
Automatic lets Record Health Check infer Text, Number, Boolean, Date, or another supported value type from the formula result. Use an explicit type when the example requires predictable formatting. The display formulas affect Found and Expected on the card, not PASS or FAIL.
Applies To is on the Record Health Check Custom Metadata form. A false applicability formula
produces SKIPPED. A formula that Salesforce accepts in metadata can still become Unable to Check
at runtime if a field is unavailable to the running user or the expression cannot be evaluated in
that org, so test with intended field permissions.
Formula evaluation uses the running user’s access to the record and fields. Test the passing and failing cases with the access assigned to intended users, not only with administrator access.
For every Formula setting, outcome, security check, and limit, use Reference: Formula.