Winter Special Limited Time 65% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: bigdisc65

PDII Exam Dumps - Salesforce Developers Questions and Answers

Question # 34

Consider the following code snippet:

Choose 2 answers

Options:

A.

Store the URL of the endpoint in a custom Label named endpointURL.

B.

Create a Named Credential, endpoint_NC, to store the endpoint and credentials.

C.

Use reg.setEndpoint(Label.endPoinrURL);,

D.

Use req.setEndpoint,calloat;eodPolat NC'); within the callout request.

Buy Now
Question # 35

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)

Options:

A.

Option A

B.

Option B

C.

Option C

Buy Now
Question # 36

A developer created and tested a Visualforce page in their developer sandbox, but now receives reports that user encounter view state errors when using it in production.

What should the developer ensure to correct these errors?

Options:

A.

Ensure queries do net exceed governor limits,

B.

Ensure properties are marked as private,

C.

Ensure variables are marked as transient.

D.

Ensure profiles have access to the Visualforce page.

Buy Now
Question # 37

Which use case can be performed only by using asynchronous Apex?

Options:

A.

Querying tens of thousands of records

B.

Making a call to schedule a batch process to complete in the future

C.

Calling a web service from an Apex trigger

D.

Updating a record after the completion of an insert

Buy Now
Question # 38

Given the following code:

Assuming there were 10 Contacts and five Accounts created today, what is the expected result?

Options:

A.

System.QueryException: Too many DML Statement errors on Contact

B.

System.QueryException: List has more than one row for Assignment on Account

C.

Systemn.LimitException: Too many SOQL Queries on Account

D.

System.LimitException: Too many SOQL Queries on Contact

Buy Now
Question # 39

A developer creates an application event that has triggered an infinite loop.

What may have caused this problem?

Options:

A.

The event is fired from a custom renderer.

B.

The event has multiple handlers registered in the project.

C.

The event handler calls a trigger.

D.

An event is fired ‘ontouchend'’ and is unhandled.

Buy Now
Question # 40

Universal Containers has an Apex trigger on Account that creates an Account Plan record when an Account is marked as a Customer.

Recently a record-triggered flow was added so that whenever an Account is marked as a Customer, a "Customer Since’ date field is updated with today's date. Since the addition of the flow, two Account Plan records are created whenever the Account is marked as a Customer.

What might cause this to happen?

Options:

A.

The Apex trigger does not use a static variable to ensure it only fires once.

B.

The flow is configured to use an "Update Records’ element.

C.

The Apex trigger is not bulk safe and calls insert inside of a for loop.

D.

The flow is configured to evaluate when a record is created and every time it is edited.

Buy Now
Question # 41

A page throws an ‘Attempt to dereference a null object’ error for a Contact.

What change in the controller will fix the error?

Options:

A.

Declare a static final Contact at the top of the controller.

B.

(o] Use a condition in the getter to return a new Contact if it is null.

G Change the setter’s signature to return a Contact.

C.

Change the getter's signature to be static Contact.

Buy Now
Question # 42

Universal Containers wants to use a Customer Community with Customer Community Plus licenses to allow their customers access to track how many containers they have rented and when they are due back. Universal Containers uses a Private sharing model for External users, Many of their customers are multi-national corporations with complex Account hierarchies. Each account on the hierarchy represents a department within the same business,

One of the requirements is to allow certain community users within the same

Account hierarchy to see several departments’ containers, based on a custom

junction object that relates the Contact to the various Account records that

represent the departments.

Which solution solves these requirements?

Options:

A.

A Visualforce page that uses a custom controller that specifies without sharing [0 expose the records

B.

An Apex trigger that creates Apex managed sharing records based on the junction object's relationships

C.

A Lightning web component on the Community Home Page that uses Lightning Data Services.

D.

A custom list view on the junction object with filters that will show the proper records based on owner

Buy Now
Question # 43

An environment has two Apex triggers: an after-update trigger on Account and an after-update trigger on Contact.

The Account after-update trigger fires whenever an Account's address is updated, and it updates every associated Contact with that address. The Contact after-update trigger fires on every edit, and it updates every Campaign Member record related to the Contact with the Contact's state.

Consider the following: A mass update of 200 Account records’ addresses, where each Account has 50 Contacts. Each Contact has one Campaign Member. This means there are 10,000 Contact records across the Accounts and 10,000 Campaign Member records across the contacts.

What will happen when the mass update occurs?

Options:

A.

There will be no error and all updates will succeed, since the limit on the number of records processed by DML statements was not exceeded.

B.

The mass update of Account address will succeed, but the Contact address updates will fail due to exceeding number of records processed by DML statements.

C.

There will be no error, since each trigger fires within its own context and each trigger does not exceed the limit of the number of records processed by DML statements.

D.

The mass update will fail, since the two triggers fire in the same context, thus exceeding the number of records processed by DML statements.

Buy Now
Exam Code: PDII
Exam Name: Salesforce Certified Platform Developer II (WI25)
Last Update: Feb 20, 2025
Questions: 196
PDII pdf

PDII PDF

$29.75  $84.99
PDII Engine

PDII Testing Engine

$33.25  $94.99
PDII PDF + Engine

PDII PDF + Testing Engine

$47.25  $134.99