What are Record Types in Salesforce?

AMIT SINGH
5 min readOct 10, 2022

--

Introduction

Before we talk about what are record types in Salesforce, Let’s talk about what is the business use case where we will be needing the various record types.

Business Use Case: You are working as a Salesforce Admin for Xcorp Ltd. Users who are part of the Sales department want to see the different set of fields on the record detail page & Users in the Marketing department wants to see different fields on the detail page for Lead Object.

Note: — Both department users want to see the different picklist values.

Whenever we need to display the different fields on the record detail page or need to display the different picklist values for the same picklist fields to different processes then we always go with Record Types in Salesforce.

What Is Record Type

Record Type is a special type of object which can be related to almost any standard or custom object.

When you create a record type for any object then a new field becomes available and the API name is RecordTypeId.

Problem Statement

Your company is dealing with two types of accounts

  • USA Customers
  • International Customers

And for USA customers the Sales users only want to see the below values for the picklist

  1. Education
  2. Technology
  3. Communications
  4. Consulting
  5. Finance

And for International Customers, want to see the below values for the Industry picklist

  1. Government
  2. Manufacturing
  3. Media
  4. Not For Profit

Create Record Types In Salesforce

As described in the problem statement, the end users want to see different picklist values so the solution would be record types.

Create two record types for accounts and the name are given below

  1. USA Customers
  2. International Customers

Follow the below steps to create the record types

  1. Login to Salesforce
  2. Navigate to Setup -> Object Manager
  3. Click on “Account” from the list.
  4. Select “Record Types” from the left panel
  5. Click the “New” Button
  6. Provide the name
  7. Click Next & Save

Repeat steps 4–7 and then create an International Customer Record Type.

Note: — Please make sure that the record types are active and available for the System Administrator Profile.

Configure Picklist Values

Now, we have set up the record types. The time is to configure the picklist values for Industry.

While you are on the account object page, Select Record Types from the left panel and select “USA Customers“.

It will open the record type detail page, where you will see the list of all picklist values.

Select Edit next to Industry picklist.

Make sure you have selected only the required values mentioned in the requirement.

Repeat the same steps for the International Customers Record Type.

Test The Setup

So far we have seen how to control the picklist values using record types.

We can also control what fields users see on the record detail page with the help of Page Layouts.

We can create a dedicated page layout for each record type.

Create Page Layouts

You have done a fantastic job and your business is very happy with you. Now they are only seeing the picklist values which are required for them.

Requirement:– Users are complaining that they are seeing unnecessary fields on the detail page and those fields are not needed.

Below are the fields required for the USA Customers

  1. Name
  2. Phone
  3. Rating
  4. Industry
  5. Parent Account
  6. Account Record Type
  7. Type
  8. Description
  9. Address

Here is the list of all fields that are required for international Customers

  1. Name
  2. Phone
  3. Industry
  4. Parent Account
  5. Description
  6. Account Record Type
  7. Address
  8. Website

Solution: As a Salesforce Admin, you have identified that page layout is the best solution for this.

Create two-page layouts for USA & International Customers.

Follow the below steps to create the page layout.

  1. Login to Salesforce
  2. Navigate to Setup -> Object Manager
  3. Click on “Account” from the list.
  4. Select “Page Layouts” from the left panel
  5. Click the “New” Button
  6. Provide the name. For Example, USA Customers
  7. Leave Existing Page Layout blank
  8. Click Save
  9. You will be taken to the Edit page of Page Layout.
  10. Drag & Drop the required fields into the page payout
  11. Click on Save

Please repeat Steps 5 to Step 11 for International Customers Page Layout

Page Layout Assignment

Perfect you have done an amazing job creating the page layouts. Now, the time is to make sure that the correct page layout is assigned to the correct record type.

Follow the below steps to assign the page layout to record types

  1. While you are on the account page select “Page layouts” from the left panel
  2. Click the “Page layout Assignment” button.
  3. Then Click on the “Edit Assignment” button.
  4. Next to System Administrator or any other profile under “USA Customer” select all the rows and then select “USA Customers” from “Page Layout To Use”
  5. Repeat step 5 for the International Customer page layout.
  6. Click Save

Test This Out

Congratulations!!!! You have done the setup of page layouts.

Create the account record with the different record types and notice the change.

--

--

AMIT SINGH

Software Developer by day & YouTube by night. Salesforce Architect || Salesforce MVP || Integration Expert