Apex articles
Page 3 of 9 · 106 articles
Stateful Batch Apex: Should You Cache Picklist Values?
Holding metadata like picklist values in stateful variables looks like a free performance win, and it brings...
Calling Apex Methods to Create Records in Loops from LWC
Bulk record creation from a Lightning Web Component: why looping Apex calls is an anti-pattern, and what a bulkified...
Detect Login As in Apex: Is SubstituteUser Reliable?
Whether the SubstituteUser session type is a dependable way to detect 'Login As', what it cannot tell you, and which...
Protected Custom Settings: Fixing Null Values from LWC
Protected Custom Settings return null in LWC because of the scope the Protected modifier applies. Here is what it...
Custom CSV Import Architecture for Salesforce Developers
A pattern for parsing, validating and mapping CSV data onto multiple Salesforce objects without blowing the heap or the...
Salesforce Web Console: The Developer Console Successor
Salesforce is launching the Web Console, a browser-based IDE built to take over from the aging Developer Console. It...
Box.com Salesforce Integration: Apex Backend Guide
How to wire Salesforce up to Box.com in Apex: secure authentication, the file upload patterns that hold up, and error...
Apex Test Class: Catching Thrown Exceptions in Async Batch Jobs
Why try/catch silently fails inside Batch Apex test classes, and the direct-invocation pattern that makes async...
PlatformCache Immutable Parameter: Why It Fails
Cross-namespace PUT errors in PlatformCache trace back to a known platform bug. Here is why the immutable parameter...
SOQL Returns Old Value After UI Update
A Salesforce UI edit looks committed, and then an Apex SOQL query reads the old value back. The mismatch between the UI...
Email Limits: DailyWorkflowEmails vs SingleEmail Explained
Salesforce email limits follow the recipient type, so the tool you send from (Flow, Apex, anything else) does not...
Alternatives to Salesforce Validation Rules for Developers
Validation Rules protect data quality by blocking the save, which is exactly why users learn to work around them. Five...