Activity › Forums › Salesforce® Discussions › What are the Apex best practices in Salesforce ? Salesforce® Discussions What are the Apex best practices in Salesforce ? Posted by Arun on January 22, 2020 at 6:40 AM What are the Apex best practices in Salesforce ? Shweta replied 6 years, 4 months ago 3 Members · 2 Replies 2 Replies krati vishnoi Member January 22, 2020 at 12:07 PM Some of the best practices are: 1: Bulkify your Code 2: Avoid SOQL Queries or DML statements inside FOR Loops 3: Bulkify your Helper Methods 4: Use of the Limits Apex Methods to Avoid Hitting Governor Limits 5: Avoiding Hard coded IDs For details go to: https://developer.salesforce.com/page/Apex_Code_Best_Practices [adinserter block='9'] Shweta Member January 22, 2020 at 1:43 PM Apex best practices in Salesforce are : Bulkify your apex code Avoid Query or DML statements inside the For loop Bulkify Helper methods Streamlining Multiple Triggers on the Same Object Use @future Appropriately Write Test Methods to Verify Large Datasets Log In to reply. Public All Members My Connections Only Me PublicAll MembersMy ConnectionsOnly Me Public All Members My Connections Only Me