This repository is part of the Developer Kickstart Module 4 curriculum at Cloud Code Academy. It's designed to help beginner Salesforce developers learn and practice the fundamental operations of the Data Manipulation Language (DML) in Apex. The focus is on the Insert, Update, Upsert, and Delete operations, all of which are essential in manipulating Salesforce data.
Through this practice repository, you'll gain foundational knowledge about:
- Understanding the different types of DML operations in Apex (Insert, Update, Upsert, and Delete).
- How to use DML operations to create, update, and delete records in Salesforce.
- The structure and usage of Salesforce standard objects like Account, Contact, Opportunity, and Lead.
- How to handle bulk data operations in Apex.
- Understanding the concept of governor limits in Salesforce and how to write efficient, bulkified Apex code.
This foundational knowledge will prepare you for more advanced topics in Salesforce development, such as exception handling, asynchronous Apex, and trigger development. The curriculum includes practical examples with Salesforce standard objects to provide hands-on experience with DML operations.
Certain test methods related to the Book and Person classes are currently commented out and will need to be uncommented and deployed once the relevant classes are set up.
- Create/Configure a trailhead playground or developer org to do your work throughout this program.
- Install Visual Studio Code from here.
- Install Salesforce Extension Pack in Visual Studio Code. This can be done by searching 'Salesforce Extension Pack' in the Extensions view in VS Code and clicking Install.
- Authorize your org in Visual Studio Code. Press
Ctrl + Shift + P
to open the command palette and type 'SFDX: Authorize an Org', then press Enter. Follow the steps in the browser to log in to your org, then return to VS Code. - Make sure to save and deploy your changes into Salesforce from your local machine. This can be done through the command pallet or right clicking the file you want to deploy and using the option
SFDX: Deploy this source to org
To run the test classes:
- Open the command palette with
Ctrl + Shift + P
. - Type 'SFDX: Invoke Apex Tests...', and press Enter.
- In the 'Select Test Class' input, select the test class you want to run and press Enter.
- The test results will appear in the Output panel at the bottom of the screen. You can switch to the 'Test' tab in this panel to see a summary of the test run.
If you get stuck at any point, here are some resources that might help:
- Apex Developer Guide
- Salesforce Stack Exchange
- Visual Studio Code Documentation
- Salesforce Extensions for Visual Studio Code
And remember, programming is often about solving problems, so don't be afraid to use search engines to find answers to your questions.
Good luck with your learning journey in Salesforce development!