๐Ÿš€ Salesforce Interview Mastery

LWC, Apex & Integration Questions with Real-World Solutions

๐Ÿ“‹ 4+ Year Salesforce Developer Interview Checklist

0
Completed
0
Total Topics
0%
Progress

โš™๏ธ APEX (Core Language)

๐Ÿ“Œ Basics

๐Ÿ—๏ธ OOP & Design

๐Ÿ”„ Database Operations

โšก Advanced Patterns

๐Ÿš€ Async Apex

โšก LIGHTNING WEB COMPONENTS (LWC)

๐Ÿ“Œ Basics

๐Ÿ”„ Communication

๐ŸŽฏ Advanced Patterns

๐Ÿ“ฑ UI & Performance

๐Ÿงช Testing & Deployment

๐Ÿ”€ FLOWS & AUTOMATION

๐Ÿ“Œ Flow Fundamentals

๐ŸŽฏ Advanced Flows

๐Ÿค– Automation

๐ŸŒ INTEGRATIONS

๐Ÿ“ก APIs & Callouts

๐Ÿ”” Events & PubSub

๐Ÿ” Security

โš™๏ธ SALESFORCE ADMIN & CONFIGURATION

๐Ÿ“Š Data & Objects

๐Ÿ” Security & Access

๐Ÿ“‹ Process & Customization

๐Ÿงช TESTING & DEPLOYMENT

โœ… Apex Testing

๐Ÿš€ Deployment

๐Ÿ” Debugging

๐ŸŽฏ MISCELLANEOUS & ADVANCED

๐Ÿ“š Advanced Topics

๐ŸŒŸ Soft Skills & Interview Prep

๐ŸŽฏ Real-World Scenarios

Scenario 1: Loading 1000+ Records in LWC

+

Scenario 2: Dynamic SOQL with User-Selected Filters

+

Scenario 3: Drag-and-Drop List Reordering

+

โšก LWC-Specific Questions

LWC renders in App Builder but fails in Flow Screen. Why?

+

LWC shows stale data after record update. refreshApex() doesn't help?

+

Child component emits CustomEvent but parent doesn't receive it?

+

What is the difference between LWC and Aura components?

+

How do @api, @track and @wire differ?

+

What are the main lifecycle hooks in LWC and typical uses?

+

How do reactive properties and getters work in LWC?

+

When to use @wire vs imperative Apex?

+

How to use Lightning Data Service (LDS) with LWC?

+

How to handle navigation and deep links in LWC?

+

How to use Lightning Message Service (LMS) to communicate across DOM boundaries?

+

How to create accessible and slotted components?

+

Best practices for performance (debounce, memoize, virtual list)?

+

Security: what does Locker Service restrict and how to secure LWC?

+

How to write Jest tests for LWC and mock Apex/wired adapters?

+

Meta.xml: how to expose LWC to App Builder and Flow?

+

How to test wired methods and adapters in Jest?

+

How to handle file uploads and ContentVersion in LWC?

+

What is lwc:dom="manual" and when to use it?

+

How to lazy-load libraries (loadScript, loadStyle)?

+

How to use lightning-record-form and intercept submit?

+

How to use getRecordNotifyChange to refresh LDS caches?

+

How to create modals and manage focus for accessibility?

+

How to implement optimistic UI updates in LWC?

+

How to use getObjectInfo and getPicklistValuesByRecordType?

+

How to validate forms and provide user-friendly errors?

+

How to handle platform events and empApi in LWC?

+

How to display toast messages from LWC?

+

How to implement a simple pubsub for sibling communication?

+

How to handle third-party analytics and privacy in LWC?

+

How to handle navigation in Communities (Experience Cloud)?

+

How to handle error boundaries and show fallback UI?

+

How to access custom labels and translations?

+

How to mock LMS in Jest tests?

+

How to use dynamic imports (import()) in LWC?

+

How to manage long-running operations and show progress?

+

How to detect network offline state and queue updates?

+

How to use Service Components and share logic across components?

+

How to optimize render cycles and avoid re-render thrash?

+

How to use keyboard accessibility (focus management) in custom elements?

+

How to debug performance with LWC profiler and Chrome DevTools?

+

How to secure Apex methods called from LWC?

+

How to write snapshot tests for LWC styling?

+

๐Ÿ› ๏ธ Apex Triggers โ€” Detailed Answers

What is an Apex Trigger and why do we use it instead of declarative tools?

+

Explain the difference between before triggers and after triggers. When should each be used?

+

What are the main trigger context variables? List and explain at least 10.

+

What does Trigger.isExecuting indicate? In what scenarios is it useful?

+

What are the major trigger events supported in Salesforce?

+

Which trigger contexts have access to Trigger.new and Trigger.old? When are they null?

+

What is Order of Execution? Where do triggers fit within it?

+

In which contexts are record IDs available and not available?

+

What are Undelete triggers and when are they used?

+

How do validation rules and workflow field updates affect triggers?

+

Why adopt โ€œOne Trigger Per Objectโ€? What problems does it avoid?

+

What is a Trigger Handler pattern? Show a basic structure and benefits.

+

How do you bulkify triggers? What mistakes break bulkification?

+

Why should you avoid SOQL/DML inside loops? Provide a refactoring example.

+

What techniques help prevent recursion in triggers? Outline a pattern.

+

When should you use static variables in trigger frameworks?

+

How do you ensure CRUD/FLS compliance in trigger code?

+

What is the impact of with sharing / without sharing on trigger-executed code?

+

How do you decide between a trigger and Flow/Process Builder/LWC + Apex?

+

What are common anti-patterns in trigger development, and how do you avoid them?

+

Explain insert, update, upsert, delete, undelete and their use in triggers.

+

What is the difference between DML statements and Database class methods (e.g., Database.update)?

+

What is allOrNone? When do you use partial success and how to handle results?

+

How do you use addError()? What does it do to the transaction?

+

What happens if you try to update a record in an after update trigger?

+

How do you perform cross-object updates safely in triggers?

+

What is upsert with external IDs and how does it affect trigger logic?

+

How do you handle trigger-induced field updates without causing infinite loops?

+

How do you perform a rollup (SUM/COUNT/MAX) to a parent without a Roll-Up Summary field?

+

How do Workflow, Process Builder, Flows, and Trigger interactions cause unexpected behavior? How to mitigate?

+

How do you avoid SOQL in a loop in triggers? Provide a before/after code example.

+

Explain relationship queries in SOQL within trigger code.

+

What makes a query non-selective? How does it affect triggers?

+

What tools/techniques help diagnose SOQL selectivity?

+

How do indexes and skinny tables help with trigger performance?

+

How do you handle large data volumes inside triggers (bulk updates, batch strategies)?

+

Which Governor Limits are most commonly hit by triggers, and how do you avoid them?

+

How do you implement a Trigger Framework (handler, dispatcher, context routing)?

+

How do you handle ordered execution of business logic in a single trigger?

+

How do you chain async jobs (Queueable) from triggers responsibly?

+

How do you publish or subscribe to Platform Events from trigger logic?

+

How do you disable triggering logic for specific users, profiles, or contexts?

+

How do you handle cross-object recursion (Object A updates Object B which updates Object A)?

+

How do you safely call external APIs (callouts) from operations caused by triggers?

+

How do you design triggers to be integration friendly (idempotency, retries)?

+

What are best practices for testing triggers?

+

How do you test asynchronous logic initiated from triggers?

+

What common pitfalls cause deployment failures for triggers, and how do you prevent them?

+

๐Ÿ”„ Async & Queueable Questions

Queueable enqueues another conditionally. Works in test, fails in production?

+

Trigger updates record, fires another trigger. No recursion guard, yet no infinite loop?

+

Batch Apex finishes with "Completed" but some chunks never processed?

+

๐ŸŒ Integration Questions

Callout timeout occurs after external system processes request?

+

Callout succeeds (HTTP 200) but integration fails functionally?

+

External API returns partial data with no error code?

+

โšก Real-Time Scenarios (Most Important!)

Data Volume Issue: 500K+ records need to be updated. How do you approach this?

+

Governor Limit Failure: DML limit exceeded during batch job. What went wrong?

+

Production Bug: Trigger fires on all records but should only process specific ones. How to debug?

+

๐Ÿ—๏ธ Apex Frameworks & Best Practices

What is Apex, and how does it relate to the Salesforce multi-tenant architecture?

+

Explain the difference between Apex Classes, Triggers, and Anonymous Apex.

+

What are Governor Limits in Apex, and why do they exist?

+

Describe the Apex execution context and how it differs between synchronous and asynchronous operations.

+

What are primitive, sObject, collection, and enum types in Apex? Provide examples.

+

How do static variables behave in Apex across transactions? When are they reset?

+

Explain the difference between public, private, protected, and global access modifiers in Apex.

+

What is the difference between Database.insert and insert, and when would you use one over the other?

+

How do you handle null checks and null pointer exceptions idiomatically in Apex?

+

What are Apex annotations (e.g., @future, @testVisible, @AuraEnabled), and what do they do?

+

How does inheritance work in Apex? Provide an example of a base class and a subclass.

+

What are interfaces in Apex, and how do they compare to abstract classes?

+

Explain encapsulation and polymorphism in the context of Apex.

+

How does Apex overloading differ from overriding? Give examples.

+

What is the purpose of the virtual keyword, and when would you use it?

+

How do you use inner classes in Apex, and what are typical use cases?

+

What are custom exceptions in Apex? Show how to define and throw one.

+

Describe the Singleton pattern in Apex and a scenario where it is beneficial.

+

๐Ÿ”€ Flows (2026 Interview Favorite!)

What is a Flow in Salesforce?

+

What are the different types of Flows available in Salesforce?

+

What is a Screen Flow and when should you use it?

+

What is a Record-Triggered Flow?

+

What is the difference between before-save and after-save flows?

+

What is a Scheduled Flow in Salesforce?

+

What is a Platform Eventโ€“Triggered Flow?

+

How does a Record-Triggered Flow differ from a Workflow Rule or Process Builder?

+

What are entry conditions in Record-Triggered Flows?

+

What is the significance of the โ€œoptimization modeโ€ setting in Flows?

+

What is a Flow Interview?

+

What are Flow Elements?

+

What is an Assignment Element used for in Flow?

+

What is a Decision Element and how does it work?

+

What is a Loop Element in Flow?

+

How do you avoid infinite loops in Record-Triggered Flows?

+

What is the difference between a Variable and a Constant in Flow?

+

What is a Flow Resource?

+

What types of data can be stored in Flow Variables?

+

What are Collection Variables in Flow?

+

How do you update multiple related records in a Flow?

+

How do you call Apex from Flow using an invocable method?

+

What is an invocable variable in Apex?

+

What is the difference between โ€œGet Recordsโ€ and โ€œLookupโ€ in Flow?

+

How do you prevent SOQL-like limits from being hit in Flows?

+

What is the use of โ€œGet Records โ€“ Only the first recordโ€ option?

+

What are Fault Paths in Flow?

+

How do you handle errors in Flows?

+

What is a Subflow and when should you use it?

+

How do you pass values between a Flow and a Subflow?

+

How does Flow handle bulk record updates?

+

What is the order of execution in Salesforce and how do Flows fit into it?

+

What governs whether a Flow runs before or after validation rules?

+

How do you trigger a Flow from a button?

+

How do you embed a Flow in a Lightning Page?

+

How do you deploy Flows between environments?

+

What is a Flow Version?

+

Can you have multiple active versions of a Flow?

+

What are Flow limits in Salesforce (queries, DML, etc.)?

+

What is the difference between Flow Orchestrator and Flow Builder?

+

How do you debug a Flow?

+

What is the Flow Debugger and how is it used?

+

How do you log Flow operations for troubleshooting?

+

How do you use Paused Flow Interviews?

+

What are the best practices for designing scalable Flows?

+

When should you choose Flow over Apex?

+

When should you choose Apex over Flow?

+

What is the recommended way to migrate from Process Builder to Flow?

+

How do you test Flows in Salesforce?

+

What are common Flow design anti-patterns and how do you avoid them?

+

๐Ÿ” SOQL & Data Modeling

What is SOQL in Salesforce and how is it different from SQL?

+

What objects can be queried using SOQL?

+

What are the different SOQL query clauses?

+

What is a SELECT clause and what fields can be included?

+

How do you filter results using the WHERE clause in SOQL?

+

What are comparison operators available in SOQL (e.g., =, !=, LIKE)?

+

How does the LIKE keyword work in SOQL?

+

What is the IN operator used for in SOQL?

+

How do you query records using NOT IN?

+

What is the LIMIT keyword in SOQL used for?

+

How does the ORDER BY clause work in SOQL?

+

What is NULL handling in SOQL and how do you query for NULL values?

+

How do you perform aggregate queries using COUNT(), SUM(), AVG(), MIN(), and MAX()?

+

What is GROUP BY in SOQL and when is it used?

+

What is the HAVING clause and how is it used in SOQL?

+

Can you use ORDER BY with GROUP BY? How?

+

What are relationship queries in SOQL?

+

What is a child-to-parent SOQL query? Provide an example.

+

What is a parent-to-child SOQL query (subquery)? Provide an example.

+

What is the difference between inner and outer relationship queries?

+

How do you query multi-level parent relationships?

+

Can you query multi-level child relationships? Why or why not?

+

How do you query polymorphic fields like WhoId or WhatId?

+

What is a semi-join in SOQL? Give an example.

+

What is an anti-join in SOQL? Give an example.

+

What are SOSL and SOQL differences?

+

When should you use SOQL instead of SOSL?

+

Can SOQL query deleted records? How?

+

What is ALL ROWS keyword in SOQL?

+

How do you access Query Plan in Developer Console?

+

What is a selective query?

+

What causes a query to become non-selective?

+

How do indexes improve SOQL performance?

+

What are custom indexes and how do you request them?

+

How do skinny tables impact SOQL performance?

+

What is the 100 SOQL query limit and how do you avoid exceeding it?

+

Why must we avoid writing SOQL inside loops?

+

What is the difference between returning a list vs a single sObject from SOQL?

+

How do you handle queries that return no rows?

+

How do you query picklist field values using SOQL?

+

How do you query formula fields in SOQL?

+

Can you use SOQL to update fields directly? Why or why not?

+

How does FOR UPDATE work in SOQL?

+

What is OFFSET in SOQL and what are its limits?

+

How do you use TYPEOF in SOQL?

+

How do you query records using date functions like YESTERDAY, LAST_N_DAYS, etc.?

+

How do you bind Apex variables inside SOQL queries?

+

What are the performance considerations for queries on large data volumes?

+

How do you use the WHERE clause with multiple AND/OR conditions?

+

How do you debug and optimize slow SOQL queries?

+

Unit-test snippets: Select query patterns

+

๐Ÿ”’ Security & Sharing

OWD, Role Hierarchy, and Sharing Rules: What's the difference?

+

WITH sharing vs WITHOUT sharing: When do you use each and what's the difference?

+

FLS (Field-Level Security): How do you check FLS in Apex?

+

๐Ÿ“ก REST vs Platform Events & Integrations

REST API vs Platform Events: When to use which?

+

Named Credentials: How do you securely store and use API credentials?

+

Error Handling & Retries: How do you build resilient integrations?

+