Free Platform Developer II sample questions
Real questions from the Salesforce Certified Platform Developer II practice bank, with the correct answer and an explanation for each one. No junk, no filler.
Try them in the simulator Same questions, with study, timed and flashcard modes.
Showing 10 of 20 free sample questions.
A developer is building a Lightning Web Component to display a list of related `Case` records on an `Account` page. The component must be reusable and configurable by an administrator, allowing them to specify the `Status` and `Priority` to filter the cases shown. How should the developer implement this configurability for the Lightning App Builder?
Universal Containers needs to synchronize large volumes of `Product__c` records (potentially over 1 million) nightly from an external Product Information Management (PIM) system. The process involves complex transformations and enrichment logic that cannot be handled by middleware. A developer has decided to implement this using Batch Apex. To optimize performance and avoid governor limit issues, what is the best approach for the `start` method to query the records to be processed?
A developer needs to write a unit test for a method that makes an HTTP callout to an external weather service. The test must verify the logic that parses the JSON response and updates a `Forecast__c` record. Which two approaches are necessary to ensure the test runs successfully without making a real callout and properly isolates the test data? (Select TWO)
A Visualforce page uses a custom controller to display a data table of `Opportunity` records. The controller uses a large, complex SOQL query to gather the data. Users report that the page sometimes throws a 'Maximum view state size limit exceeded' error, especially when filtering results that return many rows. Which modification is the most effective way to mitigate this specific error?
Quantum Logistics has a complex, multi-lingual Salesforce org. They need to store configuration data for a custom shipping calculator, including shipping rates, service levels, and country-specific surcharges. This configuration data must be deployable between sandboxes and production, and it needs to be easily queryable within Apex. The data structure is relational, with 'Service Levels' being a parent to 'Country Surcharges'. What is the most appropriate solution for storing this configuration data?
A developer at a large enterprise is tasked with creating a nightly batch job that deactivates `Contact` records that have not been logged into a community for over 180 days. The org contains over 10 million `Contact` records. The initial SOQL query `SELECT Id FROM Contact WHERE LastLoginDate < LAST_N_DAYS:180` is timing out. What is the most effective way to resolve this query performance issue?
True or False: When using the `Database.upsert` method with an External ID field, if multiple records in the database match the provided External ID, the operation will throw a DML exception.
A developer needs to expose an Apex method that can be called from a Process Builder or Flow. The method should accept a list of `Opportunity` IDs and perform a complex calculation that is not possible with declarative tools. Which annotation must be used for the Apex method?
A business process requires that when an Opportunity is updated, a callout is made to an external system to reserve inventory. This callout must not delay the saving of the Opportunity record. If the callout fails, it should be automatically retried up to three times. Which asynchronous Apex pattern best meets all these requirements?
10 more free samples are waiting
Create a free account to unlock the whole Platform Developer II sample bank, or get full access to all 251 practice questions in the simulator.