Skip to main content
Gainsight Inc.

Load Scorecard 2.0 data to CustomerInfo object

This tutorial explains you the process of loading Scorecards 2.0 data to the Customer Info object By loading Scorecard 2.0 data to Customer Info object you can have all the customer related information in one object and easily generate reports. Scorecard 2.0 values/data reside in MDA and CustomerInfo object contains all the other info related to customers. By adding the scoring information as well to the Customer Info object, all the customer info can be found at one place (CustomerInfo). 

Firstly, create two custom fields in the Customer Info object to store Current and Previous scorecard 2.0 scores. 

  1. Current score 2.0 of Number datatype - To store current scores. 
  2. Score Previous 2.0 of Number datatype - To store previous scores.

Following is an illustration of the steps performed in this bionic rule

steps performed in this bionic rule.png

Create Custom fields on Customer Info object

  1. In Salesforce, go to Setup > Create > Objects
  2. Click the Customer Info object.

Create Custom fields on Customer Info object.gif

  1. Click New in the Custom Fields & Relationships section. 
  2. Select Number as the data type and click Next

Create Custom fields on Customer Info object1.gif

  1. Specify Field Label as Current Score 2.0
  2. Click Next and proceed to Step 4. 

Create Custom fields on Customer Info object2.png

  1. Click Save and repeat the process from Step 3 to add Previous Score 2.0 as Field Label.

Create Custom fields on Customer Info object3.png

Two new fields are created with the names Current Score 2.0 and Previous Score 2.0. These two fields are used to store scorecard data from 2.0 in Customer Info object. 

Create a Rule to fetch and load scorecard 2.0 data

In this rule, we use the fetch task type in bionic rules and use a merge task to achieve the output.

Create the following tasks in the Bionic Rule:

  1. Fetch Company Data - In the first fetch task, select Matrix Data and select Company object. 
    • Add SFDC Account ID and GSID as the Show fields and save the fetch task. 
  2. Fetch Scorecard Fact ID - In the second fetch task, select Matrix Data and select Account Scorecard Scorecard Fact object. 
    • Add Company ID, Current Score ID, Previous Score ID, Measure ID and save the fetch task. 
  3. Merge 1 - Merge the outputs of Company data and Scorecard Fact ID.
    1. Select Retain all records from the right dataset as the join type. 
    2. Unselect GSID
    3. Select the Show Selected box. 

Merge 1.png

  1. Fetch Measure Name - Fetch measure names from the Scorecard Measures object in MDA. 
    • Select GSID and Name as the Show fields. 
  2. Merge 2 - Merge the outputs of Merge 1 and Fetch Measure Name. 
    1. Select Retain all records from the right dataset as the join type. 
    2. Unselect GSID
    3. Select the Show Selected box. 

Merge 2.png

  1. Fetch Current Score - Select Scoring Scheme Definition object in Matrix Data to fetch the current score. 
    • Select GSID, Label, and Score as the Show fields and save the fetch task. 
  2. Merge 3 - Merge the outputs of Merge 2 and Fetch Current Score. 
    • Select Retain all records from the left dataset as the join type. 
    • Unselect GSID.
    • Select the Show Selected box.

Merge 3.png

  1. Fetch Previous Score - Use Scoring Scheme Definition object in Matrix Data to fetch the previous score. 
    • Add GSID, Label, and Score as the Show fields and save the fetch task. 
  2. Merge 4 - Merge the outputs of Merge 3 and Fetch Previous Score. 
    1. Select Retain all records from the left dataset as the join type. 
    2. Unselect GSID.
    3. Select the Show Selected box. 

Merge 4.png

  1. Fetch scorecard comments - Use Account Scorecard Fact object in Matrix Data to fetch the comments. 
    • Add Comments, Company ID as the Show fields and save the fetch task. 
  2. Merge 5 - Merge the outputs of Merge 4 and Fetch scorecard comments. 
    1. Select Retain all records from the left dataset as the join type. 
    2. Unselect GSID.
    3. Select the Show Selected box 
  3. Click Save

Merge 5.png

Load to Customer Info object 

  1. Proceed to Setup Action step. 
  2. Click + ACTION and select Merge 5
  3. Select Load to Customers
  4. Map the following items on this page: 
    1. Current Score with Current Score 2.0 (Double)
    2. Previous Score with Previous Score 2.0 (Double)
    3. SFDC Account ID with Account (Reference)
    4. Comments with Scorecard Comments (Text Area)

Snag_6e9bd610.png

  1. Save the action. 
  2. Proceed to Schedule step and schedule the rule as per your requirement. 
  • Was this article helpful?