Salesforce PDII Salesforce Certified Platform Developer II Online Training
Salesforce PDII Online Training
The questions for PDII were last updated at Feb 28,2026.
- Exam Code: PDII
- Exam Name: Salesforce Certified Platform Developer II
- Certification Provider: Salesforce
- Latest update: Feb 28,2026
A Salesforce org has more than 50,000 contacts. A new business process requires a calculation that aggregates data from all of these contact records. This calculation needs to run once a day after business hours.
Which two steps should a developer take to accomplish this? Choose 2 answers
- A . Use the @future annotation on the method that performs the aggregate calculation.
- B . Implement the schedulable Interface In the class that contains the aggregate calculation method.
- C . Use the areadOnly annotation on the method that performs the aggregate calculation.
- D . Implement the Queuable Interface in the class that contains the aggregate calculation method.
What should be added to the setup, in the location indicated, for the unit test above to create the controller extension for the test?

A)
![]()
B)
![]()
C)
![]()
D)
![]()
- A . Option A
- B . Option B
- C . Option C
- D . Option D
A developer 15 tasked with creating an application-centric feature on which end-users can access and update information. This feature must be available in lightning Experience while working seamlessly in multiple device form factors, such as desktops, phones, and tablets. Additionally, the feature must support Addressable URL Tabs and interact with the Salesforce Console APIs.
What arm two approaches a developer can take to build the application and support the business requirements? Choose 2 answers
- A . Create the application using Aura Components wrapped in Lightning Web Components.
- B . Create the application using Lightning web Components wrapped in Aura Components.
- C . Create application using Aura Components.
- D . Create the application using Lightning Experience Builder.
A developer created a Lightning web component for the Account record page that displays the five most recently contacted Contacts for an Account. The Apex method, getRecentContacts, returns a list of Contacts and will be wired to a property in the component.

Which two lines must change in the above ode to make the Apex method able to be wired? Choose 2 answers
- A . Add AuraEnanled(cacheabletrue) to the line 08
- B . Remove private from line 09.
- C . Add @AuraEnabled (cacheabletrue) to line 03.
- D . Add public to line 04.
A developer wrote the following method to find all the test accounts in the org:

What should be used to fix this falling test?
- A . Test. loaddata to set up expected data
- B . Test. fixedSearchResults ( ) method to set up expected data
- C . @isTest (See AllData=true) to access org data for the test
- D . @testSetup method to set up expected data
Just prior to a new deployment, the Salesforce Administrator who configured a new order fulfillment process in a developer sandbox suddenly left the company. The users had fully tested all of the changes in the sandbox and signed off on them.
Unfortunately, although a Change Set was started, it was not complete. A developer is brought in to help finish the deployment.
What should the developer do to identify the configuration changes that need to be moved into production?
- A . Leverage the Setup Audit Trail to review the changes made by the departed Administrator and identify which changes should be added to the Change Set.
- B . Use the Metadata API and a supported development IDE to push all of the configuration from the sandbox into production to ensure no changes are lost.
- C . Set up Continuous Integration and a Git repository to automatically merge all changes from the sandbox metadata with the production metadata.
- D . In Salesforce setup, look at the last modified date for every object to determine which should be added to the Change Set.
A developer creates a Lightning web component to allow a Contact to be quickly entered-However, error messages are not displayed.

Which component should the developer add to the form to display error messages?
- A . apex:messages
- B . aura:messages
- C . lightning-messages
- D . lightning-error
A developer is asked to create a Lightning web component that will be invoked via button on a record page. The component must be displayed in a model dialog.
Which three steps should the developer take to achieve this? Choose 3 answers
- A . Add a tarqetConfig anf set targets to lightning_RecordAction.
- B . In targetConfigs, add Lightning_Apppage as a target.
- C . Set action Type to screenAction.
- D . In target, add lightning_RecordAction as a target.
- E . Set eventType to action.
There are user complaints about slow render times of a custom data table within a Visualforce page that loads thousands of Account records at once.
What can a developer do to help alleviate such issues?
- A . Upload a third-party data table library as a static resource.
- B . Use JavaScript remoting to query the accounts.
- C . Use the standard Account List controller and implement pagination.
- D . Use the transient keyword in the Apex code when querying the Account records.
In a previous data audit, It was determined that close to 5 million Opportunity records are stored within the Salesforce environment. The organization-wide default for the object are set to Public Read-Only and most opportunities are related to an external case.
The method is called from a Lightning web component. Some end users do not provide a cased value and experience low performance while running the query.
Which two techniques should the developer implement to avoid low performance queries from executing? Choose 2 answers
- A . Implement a LIMIT clause within the SOQL query to restrict the result set.
- B . Ensure the user-provided input is not null before executing the SOQL query.
- C . Implement the with sharing keyword on the Apex class.
- D . Use SOSL instead of SOQL queries to perform text-based searches.