FlashKeepers

Salesforce · Salesforce PD1

Salesforce Platform Developer I: Apex Basics

Apex syntax, triggers, and governor limits concepts tested on the Salesforce Platform Developer I exam.

39 cards · basic cards · AI-written, checked twice. Edit anything.

Study this set free Look inside first Get FlashKeepers for iPhone
What is Apex?
Salesforce's proprietary, statically typed programming language for building business logic
Define a trigger in Apex.
Code that executes automatically in response to DML operations (insert, update, delete) on Salesforce records
What does Trigger.new reference?
List of records being inserted or updated in the current transaction
What does Trigger.old reference?
List of records with their pre-update values before the update is applied
What is Trigger.operationType used for?
To determine which DML operation (insert, update, delete, undelete) triggered the code
What is a governor limit?
A maximum resource threshold enforced by Salesforce to prevent any single execution from monopolizing shared infrastructure
What is the governor limit for SOQL queries per transaction?
100 queries
What is the governor limit for records returned in a SOQL query?
50,000 records
What is the governor limit for DML statements per transaction?
150 DML statements
What is the governor limit for records processed by DML statements?
10,000 records total
What is SOQL?
Salesforce Object Query Language, a syntax for querying Salesforce records
What is a SOQL for loop and when should it be used?
A loop that retrieves records in batches to process large datasets without hitting the 50,000 record limit
What DML statements are available in Apex?
insert, update, upsert, delete, undelete
What exception is thrown when a DML operation fails?
DmlException
What is the difference between insert and database.insert()?
insert throws an exception on failure; database.insert() returns a SaveResult with success/failure details

24 more cards in the app