PatronManager Help

Ensuring Quality Data Entry: Required Fields, Dependent Fields, and Validation Rules

Updated on

Use this link to share with your colleagues:

Ensuring Quality Data Entry: Required Fields, Dependent Fields, and Validation Rules: https://help.pm.leapevent.tech/a/1664899

Clean, quality data is invaluable to your organization.  With clean data, you know every report you run for your executive director or board chair will be accurate, and you know your mailing lists won't go to the wrong people.  Non-profit nirvana. 

While you can always work on cleaning your data after it's been entered, you know what they say: A stitch in time saves nine.

In this article, we'll talk about some tools at your disposal to make sure that data is entered correctly:

To help set you up for success, we’ve put guidelines together to help you avoid interfering with PatronManager functionality, corrupting your data, and to prevent negative impacts to your customizations due to PatronManager product upgrades. 

Required Fields

Required fields are just what they sound like; they require a field to be filled for a record to save. There are so many use cases for required fields, so here are some to get you thinking:

  • If you use Campaigns to track your Donations, require a Primary Campaign Source to save a Donation to ensure your development team gets accurate ROIs on Campaigns
  • If you use GL Codes to track revenue, require a GL Code to save a Ticketable Event so your finance team can easily match what's in PatronManager with your accounting software
  • If you do a lot of mailings, require some of the Salutation fields on Accounts to help your team more easily send appropriately-addressed mailings

In the example below, we can't save an Account record without filling the Formal Salutation field first:

Error message for required field

Make sure to use the page layout to require fields - do not set fields to "required" in field settings.

How to require a field

Requiring fields on the page layout is more of a "soft" requirement.  It doesn't let users save the record without filling in the field first - which is exactly what we want to accomplish.

Requiring fields via field settings can cause errors when selling tickets or taking donations, and you definitely don't want that!

1. From Setup's Object Manager, go to the object the field appears on

Object Manager in Setup

For example, we want to require the Formal Salutation field on Accounts. So from Object Manager in Setup, we'll find and select "Account."

2. Click Page Layouts

Go to Page Layouts

3. Click into a Page Layout

Click a Page Layout

In this example, we're going into the Household Layout.

4. Hover over the field you want to require, then click the wrench icon

Hover over the field, then click the wrench icon for Properties

You may need to scroll to find the field on the page layout.

5. Check Required, then click OK

Check Required then click OK

6. Check for the red star, then click Save

Click Save

7. Repeat steps 3-6 for other page layouts, if necessary

You'll need to do take these steps for all of the page layouts you want to edit.

For example, if you want to require the Formal Salutation field for Individual and Household accounts, but not Foundations or Organizations, you'd take these steps for the Household Layout and Individual Layout, but not the Foundation Layout or Organization Layout.

Do not set fields as required for any "TBQ" Record Types. Doing so can affect your ability to sell tickets or take donations online.

Dependent Picklists

Dependent picklists help you ensure accuracy for categories with subcategories: if Option 1, then choose A or B; if Option 2, then choose C or D. Dependent picklists help prevent nonsensical data and make your colleagues' lives easier.

Donation Funds are a common use case for this. For example, if we have a Fund and a Fund: Specific subcategory:

  1. For the Fund Education, the following Fund: Specific options are available
    • Free School Events
    • Visiting Artists Day
  2. For the Fund Annual Fund, the following Fund: Specific options are available
    • General Fund
    • For the Staff
Education Fund dependencies
Annual Fund dependencies

For more on how to create and use dependent picklists, check out Salesforce's help article.

How to set up field dependency

1. Make sure you've set up your controlling picklist and dependent picklist fields

Your controlling picklist determines what values are available in the dependent picklist.  

In this example, Fund is the controlling picklist and Fund: Specific is the dependent picklist.  Be sure to list out every possible value for the dependent picklist!

Need some help creating or editing these fields? We've got resources to help you with creating custom picklist fields or editing existing picklist fields.

2. In Setup's Object Manager, find and select the object with your picklists

Find and select your object

For example, our Fund and Fund: Specific picklists are on the Donation object.

3. Click Fields & Relationships

Click Fields & Relationships

4. Click Field Dependencies

Click Field Dependencies

5. Click New

Click New

6. Choose your controlling field and dependent field, then click Continue

Select your Controlling Field and Dependent Field, then click Continue

In this case, our controlling field is Fund, and our dependent field is Fund: Specific.

7. Follow the on-screen instructions to assign values from your dependent picklist to each controlling picklist value, then Save

Follow on-screen instructions to include dependent values, then click Save

Here, we've:

  1. Made General Fund and For the Staff included values in Fund: Specific when the Fund is Annual Fund
  2. Made Free School Events and Visiting Artists Day included values in Fund: Specific when the Fund is Education

You can use the Preview button to see how your field dependency will look!

Now your field dependency is set up!

Validation Rules

Validation rules can be complex, but they're also flexible. They allow you to set what criteria is required to save a record, with the criteria looking at multiple different fields.

Here are some examples of what you can do with validation rules:

  • If a Contact has the "Allergies?" checkbox checked, the "Allergy Notes" text field must contain text
  • If a Donation is created with the Major Gift record type, the Amount field must be greater than $500.00

When a user tries to save a record that violates a validation rule, the record won't save and the user will receive an error message like this:

Validation Rule Error
Here's how we set up the Major Gift validation rule

Heads up! Poorly designed validation rules can result in qualification not working as intended and can prevent your patrons from buying tickets or making donations online. Always test your validation rules in a Sandbox first.

  1. Rule Name: We named our validation rule something clear and simple
  2. Description: We've provided a description for what this validation rule does
  3. Error Condition Formula: We've provided a formula that tells the validation rule when to stop a user from saving the record.
    • Our Error Condition Formula is:
      • RecordType.Name="MajorGift" && Amount <= 500
        • This means that if the Donation has a Donation Record Type of Major Gift and the amount is less than or equal to $500.00, then the Error Message should appear
  4. Error Message: We've given a clear error message that states what needs to be fixed if the Error Condition Formula is true

If you've written formulas in PatronManager for Badges, or you've used formulas in Excel, this should look familiar to you.  If you're not familiar with either, you might find Salesforce's help article and their tips for writing formulas pretty useful.

To learn more on creating validation rules, check out this excellent Trailhead unit, which will show you the way and give you some practice to boot! If you're creating customization like validation rules, we recommend using Trailhead.

State & Country Picklists

State and Country/Territory Picklists help standardize the State and Country values that your users, your patrons, and your donors enter into the system.

They're so great, in fact, that we have an entire article dedicated to them!

Previous Article How to Adjust Search Layouts
Next Article All About Field History Tracking
Still Need Help? Continue to the Client Community