Tutorial Overview

Subject: This tutorial demonstrates one example where the Rules Engine may be used to detect inconsistencies with source Salesforce.com (SFDC) data that Gainsight leverages.
  • Parts of Gainsight the application may expect source data to be in a particular form to process accurately.  In this example, an administrator may want to set up CoPilot to process titles (such as “Executive”) and finds fewer candidates than expected!  Gainsight pulls from the SFDC instance and if the source SFDC instance does not have standardized titles, CoPilot will miss contacts.  The administrator wants to anticipate and potentially normalize source data to help their CSMs.
Complexity: Medium
Description: Employ a custom field to allow field comparisons upon update
  • Normally, a Salesforce Administrator should implement a validation rule within SFDC that would ensure that titles or other fields are consistent. 

  • Sometimes you as Gainsight Administrator may not have control over this, hence why Gainsight can be used for these kinds of things.

  • Difference is that the person using SFDC would have to change the value
  1. Create a rule that looks at the source field in SFDC and compare to a pre-defined list of titles.
  2. Create a CTA for an Admin (or CSM) to address  inconsistencies.

Notes and Tips


  • This tutorial is presented for educational purposes only
  • Always test your rules before running them in a production environment
  • Understand your Salesforce environment before performing any operations which may affect your data

Step 1 - Pre-Work

NOTE:  A demo/test environment was used to design this tutorial.  Some titles are changed in order to test desired outcomes.  These steps are presented for completeness.

Step 1a - Find the "Title" field in SFDC

  • Within SFDC, find the “Title” field
  • This is a free-form field to end-users.  Unless there are restrictions put in place, a user may type whatever title they choose

Step 1b - Create a "Definitive List" of Titles

Gainsight’s Report Builder can quickly filter on titles within SFDC.  

To inspect titles, navigate to Report Builder and create a report with the following options:

  1. Select the Contact Object
  2. Show me:
    1. Account ID Name
    2. Title
  3. Filter:  Title != null

Pick one of the companies to work with for this tutorial.  

Save as:  “Contact Titles by Company”

Step 1c - Create a Sampling of Contacts with Different Titles

In this case, an account has four (4) CSMs listed (see above)


In SFDC, alter some of the titles so there is a mix of expected and variations on titles

In this case, instead of having four "CSM" titles there are now several other variants including "Customer Success Manager", "Cust. Succ. Man.", and "C Success M".

Step 2 - Create New Rule:  "Admin - Detect Bad Contact Titles"

  1. Create a New Custom Rule “Admin: Detect Bad Contact Titles”

Step 2a - Rule Parameters

  • Using the CONTACT object (Native Data)

  • Show:

    • Contact::COUNT of Title

    • Contact::Account ID

    • Contact::Full Name

    • Account::Account Name

    • Account::CSM

      • NOTE:  This is important as we will use this to designate ownership

    • Account::CSM Name 

      • Good for testing - so we know to whom it is assigned

  • Filters

    • This is where you will list specific titles to match
 - only looking for “CSM”
    • Contact::Title | not equal to | CSM
    • Customer Info:: Account Name | equals | Citrix
  • Select the "Apply to Gainsight customers only" box

For practical purposes (there may be a LOT of titles to work with), we will focus only on “Citrix”

Step 2b - Preview Results

Click "Preview Results" - this should show three (3) titles that we entered incorrectly

Step 2c - Create a CTA

Create a CTA
 by clicking "Next" from the Setup Rule screen.  Select the "+ Action" button and create a CTA with the following parameters:

  1. Name:  
Account - ${Account::Account Name} has ${COUNT:Contact::Title} incorrectly formatted titles.  Please review and correct.

  2. Priority:  Low

    • This is not critical, but informative
 for an Admin
  3. Status: New

  4. Reason:  <PICK ANY>

  5. Type:  Event

  6. Playbook:  <NONE>

  7. Owner Field:  Account::CSM

  Account ${Account::Account Name} has ${COUNT:Contact::Title} contact titles which do not meet standard business conventions. Please refer to [PERSON OR DOCUMENT] for the approved list.

Step 2d - Test the Rule

A test will confirm that the rule detects three (3) records for Citrix

Step 2e - Run

  1. Select "Run Now"

  2. Deselect the “Test Run” checkbox
  3. Click the "Run" button to allow the CTA to be created

Step 2f - Confirm CTA Was Created

Confirm that the CTA was created correctly by navigating to Cockpit and filtering on "incorrectly formatted".

Final Notes

A rule such as this may be scheduled, or may be run on-demand depending on circumstances.  Again, this is an example of a rule which may help a Gainsight Administrator to normalize or anticipate data coming from SFDC that may affect customers downstream (CSMs, etc.).