Salesforce Configuration from Custom Metadata Types
Salesforce Configuration from Custom Metadata Types
Custom Metadata Types are a very powerful capability in the Salesforce platform it can in process builder, formulas, and validation rules. I wanted to give some background and examples to help admins understand how it could be used in their orgs. The main advantage to using the custom metadata types is you can add both definition and records in the package or changeset.
Advantages to Custom Metadata:
1. You can control the visibility of Custom Metadata Types by specifying it as public or protected.2. We can create fields like Picklist fields, long text areas also able to do with page layouts, and validation rules.
3. Asynchronous (without using remote site settings) insert/update in Apex via Metadata.MetadataOperations.enqueueDeployment()
4. Custom Metadata have a option for access for edit the records with “Configure Application” but you require “Author Apex” to edit the configuration.
5. Custom metadata is also visible for test class so no need to insert records for testing.
Some use case are following :
1. Process Builder with Formula
We have a requirement to update one field dynamically and admin can easily update accordingly without renovate the Process builder.
Step are following :
1. Create Custom Metadata for default value with the help below snapshot :
2. Validation Rules
We have a requirement to update Discount field dynamically and admin can easily update accordingly without renovate the validation rule.
Step are following :
1. Create Custom Metadata for default value with the help below snapshot :
Note : But there is a one limitation that we can't create dynamic error message for validation rule.
For more details : Custom Metadata Types
informative blog
ReplyDeleteServiceNow Online Training
ServiceNow Online Training in Hyderabad
Thanks again for the article post.Really thank you! Fantastic.
ReplyDeletebest salesforce billing training online
salesforce billing classes online