What is the use of Salesforce Audit Fields and How to Enable These fields for your Salesforce Org?
So, first discuss how to enable "Salesforce Audit Fields” in our Org. Here are the following steps:
- First, click on “Setup” in Salesforce Org.
- Now, search for “User Interface” in Quick Find Box.
- Now, Enable "Salesforce Audit Fields”.
By default, Salesforce does not have this feature enabled. This does not permit the values to be updated, only inserted.
These are the only objects where we can see the impact of "Salesforce Audit Fields":
- Account
- CampaignMember
- Case
- CaseComment
- Contact
- Content Version
- Contracts
- FeedComment
- FeedItem
- Idea
- IdeaComment
- Lead
- Opportunity
- Vote
- Work Order
- Task and Events
- All Custom Objects
- Attachments
Now, let's understand what is the use of "Audit Fields". We know Salesforce provide us functionality to set system fields through the API. When we are migrating data from an external system, the API lets you set a number of fields on objects that were previously read-only. By setting these "Audit Fields" in Salesforce, now records will appear same as we have created before, means same as the original record.