Swarnil Singhai
Author

Swarnil Singhai

Building Namaste Salesforce

Bangalore, India Website @imswarnil
The Apex mistakes I still see in every org

The Apex mistakes I still see in every org

Fifteen years of the same five mistakes: queries in loops, tests without assertions, triggers with opinions, hardcoded Ids, and empty catch blocks.

1 min read
05 · Recursion control
Business Basics

05 · Recursion control

Your after-update updates the record, which fires your after-update. Breaking the loop without breaking legitimate re-entry.

1 min read
04 · Bulkification: 200 records or bust
Business Basics

04 · Bulkification: 200 records or bust

Triggers receive up to 200 records at once. Every query and DML statement inside a loop is a countdown to 'Too many SOQL queries: 101'.

1 min read
03 · The handler pattern
Business Basics

03 · The handler pattern

One method per event, a static bypass flag, and constructor-free classes your tests will thank you for.

1 min read
02 · One trigger per object
Business Basics

02 · One trigger per object

Two triggers on one object run in an order Salesforce refuses to promise. The fix is a rule, not a framework.

1 min read
Business Basics
Business Basics

Business Basics

A business solves a problem for money. Learn what that really means, how it worked before computers, and why the definition has never changed.

8 min read
Video library launched

Video library launched

Standalone walkthroughs get their own home at /videos/ — with chapter navigation on longer recordings.

07 · Testing: proving it works
Apex for Absolute Beginners

07 · Testing: proving it works

75% coverage is the law, but coverage is not the point — assertions are. Write a test that would actually catch a bug.

1 min read