Check the parent Account's headquarters city
Create a Record Health Check that applies to Accounts with a parent Account and passes when the parent has a Billing City. When the city is missing, the card links straight to the parent Account’s edit page, because that is the record to fix. The example uses the Verify with a formula Evaluation Type with a parent relationship field.
Why a formula fits
Section titled “Why a formula fits”A formula on an Account can read fields on its Parent Account through the Parent relationship,
so one formula can check the headquarters city without a query or code. A Validation Rule on the
branch Account would block a save on the wrong record; this Check guides the user to the parent.
Before you start
Section titled “Before you start”- Install Record Health Check, and assign yourself Record Health Check Admin and the Salesforce Customize Application permission.
- Confirm that your org records headquarters on the Parent Account. If it uses another field or object, adapt the formula instead of copying it.
- Confirm that the people who will use the card can read the parent Account and its Billing City, and can edit the parent if they are expected to fix it.
Step 1: Create or choose the Check Set
Section titled “Step 1: Create or choose the Check Set”You can add the Check to an Account Check Set you already have. To create one, open Setup → Custom Metadata Types, select Manage Records next to Record Health Check Set, select New, enter these values, and save. Leave other fields at their defaults.
| Field | Value |
|---|---|
| Label | Account Data Quality |
| Object | Account |
| Record Health Check Set Name | Account_ |
| Active | Cleared until validation succeeds |
| Card Title | Account Data Quality |
| Card Subtitle | Confirm the parent Account’s location before branch handoff. |
| When Checks Run | When the user clicks Run |
Step 2: Create the Check
Section titled “Step 2: Create the Check”Open Setup → Custom Metadata Types, select Manage Records next to Record Health Check, select New, enter these values, and save.
| Field | Value |
|---|---|
| Label | Parent Account Has Billing City |
| Check Set | Account Data Quality |
| Evaluation Type | Verify with a formula |
| Record Health Check Name | Parent_ |
| Evaluation Order | 40 |
| Active | Cleared until validation succeeds |
| Pass Condition | NOT(ISBLANK(Parent. |
| Check Title | Parent Account has a Billing City |
| Check Description | Applies to Accounts with a parent. Passes when the parent Account has a Billing City. |
| Message When Failed | The parent Account of {!record. |
| Fix Message | Open the parent Account, enter its Billing City, then run the Check again on this Account. |
| Message When Unable To Evaluate | Unable to read the parent Account's Billing City. |
| Failure Severity | Warning |
| Action Label | Edit parent Account |
| Action URL | /lightning/r/Account/{!record. |
| Applies To | When a formula is true |
| Applies When (Formula) | NOT(ISBLANK(ParentId)) |
| Message When Not Applicable | {!record. |
How the values work:
Parent.BillingCityreads Billing City on the Account in the Parent Account field.- Applies When (Formula) skips Accounts with no parent, so a top-level Account never fails.
{!record.ParentId}in Action URL inserts the parent Account’s ID, so the link opens the parent’s edit page. The link does not give the user access to the parent; Salesforce still applies the user’s permissions when the page opens.
Step 3: Validate and activate
Section titled “Step 3: Validate and activate”- Run the Validate Record Health Check Configuration Flow action, as described in Validate configuration before activation, and correct every error.
- Activate the Check, then the Check Set.
- Add the Record Health Check component to the Account record page, select Account Data Quality (Account_Data_Quality), and activate the page.
- Assign Record Health Check Card User to the users who test the card.
Step 4: Test the Check
Section titled “Step 4: Test the Check”Use a sandbox Account with a parent Account. Select Run on the child Account’s card for each case.
| Parent Account | Parent’s Billing City | Result on the child Account’s card |
|---|---|---|
| Set | Blank | Warning, with Edit parent Account |
| Set | Populated | Pass |
| Blank | Not applicable | Skipped, with the not-applicable message |
Select Edit parent Account during the first test and confirm that the parent’s edit page opens. Then run a failing case as a user who cannot see the parent Account; the row shows Unable to Check.
What users see
Section titled “What users see”On a child Account whose parent has no Billing City, the row shows Warning, the message, the fix message, and an Edit parent Account link. Most users see no Found and Expected values, because the Check has no display formulas. Users directly assigned Record Health Check Admin or Record Health Check Diagnostics Viewer see Expected with the Pass Condition formula.
Resolve problems
Section titled “Resolve problems”| What you see | What to check |
|---|---|
| Every Account shows Skipped | The Account’s Parent Account field is set. |
| Unable to Check | The user can see the parent Account and read its Billing City. |
| Edit parent Account opens an error | The user has edit access to the parent Account. |