Data loading is a very common requirement in most of the salesforce projects. We need to load many master data and transactional data in production based on requirements that include thousands of records. In this article, I am going to list some best practices that we can follow and keep in mind while loading data in production. 1. Organization-Wide Sharing defaults - While loading data in production, if objects have ‘Private’ OWD then it does additional processing in the background. Therefore, it is better to load data using read/write OWD and change it to ‘private’ after cutover. 2. Workflow rules, validation rules, and triggers - If these tools are enabled in your production org while loading data, it can give many errors and it may slow down the process. Therefore, it is recommended to disable these tools before loading data. 3. Bulk API Vs. SOAP API - SOAP API is useful for small data sets where...
1. Write a schedulable class for your Batch class. · Lets us assume my batch class name is SFDC_ExecuteAccountBatch. · To schedule it we need to create a new class and implement a schedulable interface · Syntax: global with sharing class SFDC _ExecuteAccountBatchScheduler implements Schedulable { global void execute(SchedulableContext sc) { SFDC _ExecuteAccountBatch b = new SFDC _ExecuteAccountBatch(); database.executebatch(b); } } 2. Write a batch class with Schedulable interface · ...