Salesforce Certified Platform Developer II Exam
Certified Platform Developer II (Page 11 )

Updated On: 1-Feb-2026

Ursa Major Solar has a custom object, ServiceJob_c, with an optional Lookup field to Account called Partner_Service_Provider_c.

The TotalJobs_c field on Account tracks the total number of ServiceJob_c records to which a partner service provider Account is related.

What should be done to ensure that the TotalJobs_c field is kept up to date?

  1. Create an Apex trigger on ServiceJob_c.
  2. Change TotalJobs_c to a roll-up summary field.
  3. Implement a workflow cross-object field update.
  4. Build a Process Builder with an invocable action.

Answer(s): B



Refer to the following code snippet:

A developer created a JavaScript function as part of a Lightning web component (LWC) that surfaces information about Leads by wire calling getFetchLeadList when certain criteria are met.

Which three changes should the developer implement in the Apex class above to ensure the LWC can display data efficiently while preserving security? (Choose three.)

  1. Use the WITH SECURITY_ENFORCED clause within the SOQL query.
  2. Annotate the Apex method with @AuraEnabled(Cacheable=true).
  3. Implement the with sharing keyword in the class declaration.
  4. Annotate the Apex method with @AuraEnabled.
  5. Implement the without sharing keyword in the class declaration.

Answer(s): A,C,D



There is an Apex controller and a Visualforce page in an org that displays records with a custom filter consisting of a combination of picklist values selected by the user.

The page takes too long to display results for some of the input combinations, while for other input choices it throws the exception, “Maximum view state size limit exceeded”.

What step should the developer take to resolve this issue?

  1. Use a StandardSetController or SOQL LIMIT in the Apex controller to limit the number of records displayed at a time.
  2. Adjust any code that filters by picklist values since they are not indexed.
  3. Split the layout to filter records in one Visualforce page and display the list of records in a second page using the same Apex controller.
  4. Remove instances of the transient keyword from the Apex controller to avoid the view state error.

Answer(s): A



Users complain that a page is very slow to respond. Upon investigation, the query below is found to perform slowly.

Which two actions can a developer take to improve performance? (Choose two.)

  1. Make the CustomField_c field an External ID.
  2. Make the field CustomField_c required because Salesforce field indexes do not include nulls.
  3. Add a LIMIT clause to the query to reduce the number of records returned.
  4. Contact Salesforce customer support to create a custom index to include null values.

Answer(s): A,C



A developer sees test failures in the sandbox but not in production. No code or metadata changes have been actively made to either environment since the sandbox was created.

Which consideration should be checked to resolve the issue?

  1. Ensure the sandbox is on the same release as production.
  2. Ensure Workflow Rules are inactive.
  3. Ensure the Apex Classes are on the same API version.
  4. Ensure Process Builder processes are inactive.

Answer(s): B



Viewing page 11 of 86
Viewing questions 51 - 55 out of 424 questions



Post your Comments and Discuss Salesforce Certified Platform Developer II exam prep with other Community members:

Join the Certified Platform Developer II Discussion