You are currently viewing Field History Tracking in Salesforce

Field History Tracking in Salesforce

Sharing is caring!

Are you searching for a surefire way to track specific fields in Salesforce opportunities? Also do you want to easily report on the previous value and new value of the fields, and identify who makes changes and when? Besides, the business wants to use history tracking to calculate the phase duration more logically. Salesforce field history tracking is a great built-in feature when it comes to reporting on the historical data.

What is Field History Tracking?

Salesforce field history tracking is a method that can be used to track changes associated with each specific field. It can be used for both standard objects as well as custom objects that are specific to your company.

For a particular field, the process is straightforward. The field to track is selected, and the field history is displayed in the history-based list of the object. This field history data is placed for up to 18 months through the organization and 24 months via the API.

With Field History tracking, the field history of custom objects, as well as standard objects, can be tracked. The following is a list of standard objects that can be tracked:

  • Accounts
  • Articles
  • Assets
  • Campaigns
  • Cases
  • Contacts
  • Contracts
  • Contract line items
  • Entitlements
  • Leads
  • Opportunities
  • Orders
  • Order Products
  • Products
  • Price Book Entries
  • Service Contracts
  • Solutions
  • Formula, roll-up summary, or auto-number fields.
  • Created By and Last Modified By.
  • Fields that have the AI Prediction checkbox selected.
  • Master Solution Title or the Master Solution Details fields on solutions; These fields are only displayed for solutions that are translated in organizations with multilingual solutions enabled.
  • Expected opportunity income field.
  • Expected Revenue field on Opportunities.

Limitations Of Using Field History Tracking

  1. You can only track 20 fields per object.
  2. For some fields like Text Area (Long), Text Area (Rich), and Picklist (Multi-Select) and Changes to fields with more than 255 characters are tracked as edited, and their old and new values are not saved. 
  3. If a trigger causes changes to objects for which the user does not have permission to edit, the change is not tracked. Field history takes into account current user permissions.

Steps To Enable Field History Tracking 

  • From Setup, click Object Manager and select any object (For ex: Contact)
  • Select Fields & Relationships and click Set History Tracking.
  • Select Enable Contact History, and then select the fields on which you want to track the changes. (You can select maximum 20 fields on an object)
  • Click Save.

Where to see field history:  You can check the changes for the fields on which you have enabled the history tracking by adding the object history in the related list on the object layout :

  • From Setup, click Object Manager and select any object (For ex: Contact)
  • Select Page Layouts, and open a page layout on which you want to show the field history.
  • In the palette, click Related Lists.
  • From the palette, drag the Contact History related list onto the page layout and drop it below in the linked list section.
  • Click Save.

Get the field history in your Apex code:

You can quickly get the old value and new value of the fields on which you have enabled the history tracking using SOQL. 

  • For Standard Object: SELECT OldValue, NewValue, Field FROM ContactHistory
  • For Custom Object: SELECT OldValue, NewValue, Field FROM ObjectName__History

Conclusion

With Salesforce field history tracking, you can create an audit trail for required changes in your company’s essential data. This is beneficial for identifying scenarios where data is incorrectly updated and by whom.

Want to know more about Salesforce Field History Tracking? Simply contact our Salesforce certified consultants now. Our Salesforce certified experts will guide you on everything you need to know about Field History Tracking in Salesforce. Get in touch with Cloud Analogy, the Salesforce Silver Consulting Partner, now!

Deepali

Deepali Kulshrestha

Salesforce Certified Developer | Delivery Management Head
Deepali, a certified Salesforce Advanced Administrator and Salesforce Developer and CSPO Certified at Cloud Analogy, is a successful name in the industry circles when it comes to the delivery of successful projects with end-to-end testing. Deepali is a globally-renowned industry stalwart when it comes to managing Operations & Delivery Planning in driving Business Performance Management.

Hire the best Salesforce Development Company. Choose certified Salesforce Developers from Cloud Analogy now.

Leave a Reply

× How can I help you?