When it comes to working with Salesforce Data Cloud, mastering data modeling is a crucial foundational step. Whether you're a Salesforce developer, data cloud engineer, data cloud architect, or data engineer, a solid grasp of data modeling empowers efficient and effective implementation, ensures accuracy, and helps align cloud data with actionable business insights.
This guide will walk you through the core concepts of data modeling in Salesforce Data Cloud, from backend considerations to understanding the distinctions between custom objects and Data Model Objects (DMOs). We'll also explore data profiling and provide a detailed approach to structuring data using Salesforce standard objects, custom objects, and external sources.
By the end, you'll have a comprehensive understanding of where to start and how to create a robust Salesforce data model that supports scalable solutions.
Data modeling in Salesforce Data Cloud is about structuring data intentionally and systematically to create meaningful relationships. Data modeling helps businesses leverage their data to deliver actionable insights efficiently. To begin, professionals like data cloud engineers and architects must consider the following backend concepts before implementation.
1. Data Profiling
Understanding your data's goal and characteristics is the first step. Ask yourself:
Data profiling means analyzing the data to get insights into its structure, quality, and content. This step ensures you start with clean, purposeful information.
2. Data Classification
Data classification involves sorting and labeling the data based on its context and usage. Salesforce Data Cloud typically categorizes data into:
Clearly classifying data ensures that you store and handle it appropriately while enabling better segmentation and analysis downstream.
3. Data Ingestion
Data ingestion refers to bringing external data into the Salesforce Data Cloud using data streams. The objective is to move the data into Data Lake Objects (DLOs). Always ensure the data is accurate, complete, and formatted correctly before this step.
4. Data Transformation
Transformation (or data cleaning) ensures your ingested data is standardized and ready for mapping. Without transformation, inconsistent formatting or incomplete values could derail your implementation. Modify and clean your dataset through normalization, deduplication, or formatting as needed.
5. Data Mapping
Mapping is the process of associating your DLOs with Data Model Objects (DMOs) in the Salesforce Data Cloud. This can happen manually or automatically and ensures data flows correctly to key business entities for actionable insights.
By following these crucial backend steps, you're setting the stage for an optimized and accurate Salesforce data model.
Data Model Objects (DMOs) may seem similar to Salesforce custom objects at first glance, but some key differences make them unique to the Data Cloud environment. Let's explore:
a. DMO API Naming Conventions
- DMOs often use a specific naming convention. For example:
Standard objects in Salesforce Core (e.g., "Account") become ssot_Account__dlm
in the Data Cloud.
Fields follow a similar pattern. For instance:
- Salesforce Core field: Type
- Data Cloud field: ssot__AccountTypeId__c
b. Record Identifiers
Unlike Salesforce Core, where every record has a unique 18-digit ID, the Data Cloud lacks this built-in identifier. Instead, you need to designate one field as the unique identifier for your DMOs.
c. DMO Field Data Types
Here's a breakdown of supported field types in DMOs:
Note: Validation is limited in DMOs. For instance, you can input incorrect values into email, phone, or URL fields without encountering any errors.
Understanding DMOs versus custom objects ensures you're building your data models tailored to the Data Cloud's functionality.
Data profiling is like the diagnostics phase of data modeling. Analyze the structure, distribution, and relationships of your data to:
Invest time in this phase to reduce risks and errors during implementation.
Hereβs how to approach data modeling based on the object types you will work with:
1. Salesforce Standard Objects β Standard Fields
Leverage out-of-the-box standard objects and fields like Account
, Contact
, and Opportunity
. Map DLOs to these DMOs, ensuring consistency and usability.
Data profiling and Data classification not required.
2. Salesforce Standard Objects β Custom Fields
You can extend standard objects with custom fields to capture data unique to your business processes. Keep customizations streamlined to maintain performance and compatibility with updates.
Data profiling and Data classification not required.
3. Salesforce Custom Objects β All Fields
Custom objects allow you to create unique data structures tailored to your specific needs. For example, you might create a Vendor
object with fields like Vendor Code
and Contract Expiry Date
.
Data profiling Recommended and Data classification is required.
4. Non-Salesforce (External) Data
Mapping external data sources involves ingesting this data into DLOs and then aligning it with DMOs. For instance:
Customer_Engagement__c
.Data profiling and Data classification both are required.
With this framework, you have a flexible and scalable approach to building a Salesforce data model.