Data Productivity Cloud Pipeline

Author: Ian
Date Posted: Feb 8, 2024
Last Modified: Nov 29, 2024

Quickstart Salesforce Unite Lead And Contact

Use this Quickstart Data Productivity Cloud pipeline to unite the Contact and Lead Salesforce tables into a single “Person” table.

Salesforce tables used

  • Contact
  • Lead

Referring to the Salesforce Architects Sales Objects reference:

Image ofSalesforce Entity Relationship Diagram
Salesforce Entity Relationship Diagram

Integrated Salesforce object table

Output table: mtln_qs_sf_person

Granularity: One record for every Lead, plus one record for every Contact

The united table contains all columns that are common to Leads and Contacts. The following are treated specially:

  • PersonId - Contains either the Contact.Id or the Lead.Id
  • ContactId - For Contacts, the Id. For Leads, the ConvertedContactId. All Leads that have been converted into a Contact will have the same ContactId, and that ContactId will also be present in the table for the new Contact
  • AccountId - Always present for Contacts. For Leads, the value is taken from ConvertedAccountId
  • PersonType - Either Contact or Lead

Generating the integrated table

Start by opening the Orchestration pipeline:

Image ofOrchestration pipeline qs-sf-unite-lead-and-contact-orch
Orchestration pipeline qs-sf-unite-lead-and-contact-orch

Set the default value of the pipeline variable SalesforceOAuthName to the name of your Salesforce OAuth.

Run the Orchestration pipeline. It will sync your Salesforce data, and create the output table using the Transformation pipeline.

Image ofTransformation pipeline qs-sf-unite-lead-and-contact-tran
Transformation pipeline qs-sf-unite-lead-and-contact-tran

Customizing the Salesforce integrated table

  • Add more fields using the Salesforce Query components in the Orchestration pipeline, including your own custom fields
  • Add your own Table Inputs, calculations and aliases to the Transformation pipeline to customize the integration with your own data
  • You may choose to apply filters in the Transformation pipeline, in which case they will apply to all users. Alternatively, apply filters in your visualization instead

Downloads

Licensed under: Matillion Free Subscription License

Installation Instructions

How to Install a Data Productivity Cloud Pipeline