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

PDI Salesforce Certified Platform Developer 1 (WI25) Questions and Answers

Questions 4

A software company uses the following objects and relationships:

* Case: to handle customer support issues

* Defect__c: a custom object to represent known issues with the company's software

* Case Defect__c a junction object between Case and Defect __c to represent that a defect is a cause of a customer issue

Case and Defect__c have Private organization-wide defaults.

What should be done to share a specific Case_Defect__c record with a user?

Options:

A.

Share the parent Cast record Defect_c records.

B.

Share the parent Case and record_c record.

C.

Share the parent Defect__c record.

D.

Share the case_Defect_c record.

Buy Now
Questions 5

A developer writes a trigger on the Account object on the before update event that increments a count field. A record triggered flow also increments the count field every time that an Account is created or updated.

What is the value of the count field if an Account is inserted with an initial value of zero, assuming no other automation logic is implemented on the Account?

Options:

A.

4

B.

2

C.

1

D.

3

Buy Now
Questions 6

Assuming that name is a String obtained by an tag on a Visualforce page, which two SOQL queries performed are safe from SOQL injection? Choose 2 answers

A)

PDI Question 6

B)

PDI Question 6

C)

PDI Question 6

D)

PDI Question 6

Options:

A.

Option A

B.

Option B

C.

Option C

D.

Option D

Buy Now
Questions 7

What are two ways a developer can get the status of an enqueued job for a class that implements the queueable interface?

Choose 2 answers

Options:

A.

View the Apex Status page

B.

View the Apex Jobs page

C.

Query the AsyncApexJob object

D.

View the Apex Flex Queue

Buy Now
Questions 8

A developer created this Apex trigger that calls MyClass.mystaticMethod:

PDI Question 8

The developer creates a test class with a test method that calls MyClass.myStaticMethod directly, resulting in 81% overall code coverage What happens when the developer tries to deploy the trigger and two classes to production, assuming no other code exists?

Options:

A.

The deployment passes because both classes and the trigger were included in the deployment.

B.

The deployment fails because no assertions were made in the test method.

C.

The deployment passes because the Apex code has the required >75% code coverage.

D.

The deployment fails because the Apex trigger has no code coverage.

Buy Now
Questions 9

Flow Builder uses an Apex action to provide additional information about multiple Contacts, stored in a custom class, ContactInfo. Which is the correct definition of the Apex method that gets the additional information?

A)

PDI Question 9

B)

PDI Question 9

C)

PDI Question 9

D)

Options:

A.

Option A

B.

Option B

C.

Option C

D.

Option D

Buy Now
Questions 10

What are three capabilities of the tag when loading JavaScript resources in Aura components?

Choose 3 answers

Options:

A.

One-time loading for duplicate scripts

B.

Loading scripts in parallel

C.

Loading Files from Documents

D.

Specifying loading order

E.

Loading externally hosted scripts

Buy Now
Questions 11

Universal Containers wants to back up all of the data and attachments in its Salesforce org once a month.

Which approach should a developer use to meet this requirement?

Options:

A.

Schedule a report.

B.

Use the Data Loader command line.

C.

Define a Data Export scheduled job.

D.

Create a Schedulable Apex class.

Buy Now
Questions 12

Which Apex class contains methods to return the amount of resources that have been used for a particular governor, such as the number of DML statements?

Options:

A.

OrgLimits

B.

Limits

C.

Messaging

D.

Exception

Buy Now
Questions 13

A developer wants to send an outbound message when a record meets a specific criteria.

Which two features satisfy this use case?

Options:

A.

Flow Builder can be used to check the record criteria and send an outbound message.

B.

Approval Process can be used to check the record criteria and send an outbound message without Apex code.

C.

Entitlement Process can be used to check the record criteria and send an outbound message without Apex code.

D.

Next Best Action can be used to check the record criteria and send an outbound message.

Buy Now
Questions 14

A developer has a Visualforce page and custom controller to save Account records. The developer wants to display any validation rule violations to the user.

How can the developer make sure that validation rule violations are displayed?

Options:

A.

Add custom controller attributes to display the message.

B.

Use a try/catch with a custom exception class.

C.

Include on the Visualforce page.

D.

Perform the DML using the database.unsert() method,

Buy Now
Questions 15

Universal Containers implemented a private sharing model for the Account object. A custom Account search tool was developed with

Apex to help sales representatives find accounts that match multiple criteria they specify. Since its release, users of the tool report they can see

Accounts they do not own.

What should the developer use to enforce sharing permissions for the currently logged in user while using the custom search tool?

Options:

A.

Use the with sharing keyword on the class declaration.

B.

Use the without sharing keyword on the class declaration.

C.

Use the userInfo Apex class to filter all SOQL queries to returned records owned by the logged-in user.

D.

Use the schema describe calls to determine if the logged-in user has access to the Account object.

Buy Now
Questions 16

Universal Containers (UC) uses out-of-the-box order management, that has a Master-Detail relationship between Order and Order Line Item.

UC stores the availability date on each Order Line Item and Orders are only shipped when all of the Order Line Items are available.

Which method should be used to calculate the estimated ship date for an Order?

Options:

A.

Use a LATEST formula on each of the latest availability date fields.

B.

Use a CEILING formula on each of the latest availability date fields.

C.

Use a DAYS formula on each of the availability date fields and a COUNT Roll-Up Summary field on the Order.

D.

Use a MAX Roll-Up Summary field on the latest availability date fields.

Buy Now
Questions 17

What should a developer use to script the deployment and unit test execution as part of continuous integration?

Options:

A.

VS Code

B.

Execute Anonymous

C.

Salesforce CLI

D.

Developer Console

Buy Now
Questions 18

Refer to the following Apex code:

PDI Question 18

What is the value of » when it is written to the debug log?

Options:

A.

0

B.

1

C.

2

D.

3

Buy Now
Questions 19

A developer is implementing an Apex class for a financial system. Within the class, the variables 'creditAmount' and 'debitAmount' should not be able to change once a value is assigned.

In which two ways can the developer declare the variables to ensure their value can only be assigned one time?

Choose 2 answers

Options:

A.

Use the static keyword and assign its value in a static initializer.

B.

Use the final keyword and assign its value in the class constructor.

C.

Use the final keyword and assign its value when declaring the variable.

D.

Use the static keyword and assign its value in the class constructor.

Buy Now
Questions 20

Management asked for opportunities to be automatically created for accounts with annual revenue greater than $1, 000,000. A developer created the following trigger on the Account object to satisfy this requirement.

PDI Question 20

Users are able to update the account records via the UI and can see an opportunity created for high annual revenue accounts. However, when the administrator tries to upload a list of 179 accounts using Data Loader, it fails with system, Exception errors.

Which two actions should the developer take to fix the code segment shown above?

Choose 2. answers

Options:

A.

Query for existing opportunities outside the for loop.

B.

Check if all the required fields for Opportunity are being added on creation.

C.

Move the DML that saves opportunities outside the for loop.

D.

Use Database query to query the opportunities.

Buy Now
Questions 21

How does the Lightning Component framework help developers implement solutions faster?

Options:

A.

By providing device-awareness for mobile and desktops

B.

By providing an Agile process with default steps

C.

By providing change history and version control

D.

By providing code review standards and processes

Buy Now
Questions 22

A developer needs to implement a custom SOAP Web Service that is used by an external Web Application. The developer chooses to include helper methods that are not used by the Web Application in the implementation of the Web Service Class.

Which code segment shows the correct declaration of the class and methods?

A)

PDI Question 22

B)

PDI Question 22

C)

PDI Question 22

D)

PDI Question 22

Options:

A.

Option A

B.

Option B

C.

Option C

D.

Option D

Buy Now
Questions 23

A credit card company needs to implement the functionality for a service agent to process damaged or stolen credit cards. When the customers call in, the service

agent must gather many pieces of information. A developer is tasked to implement this functionality.

What should the developer use to satisfy this requirement in the most efficient manner?

Options:

A.

Screen-based flow

B.

Approval process

C.

Apex trigger

D.

Lightning Component

Buy Now
Questions 24

An org has an existing flow that edits an Opportunity with an Update Records element. A developer must update the flow to also create a Contact and store the created Contact’s ID on the Opportunity.

Which update must the developer make in the flow?

Options:

A.

Add a new Update Records element.

B.

Add a new Roll Back Records element.

C.

Add a new Create Records element.

D.

Add a new Get Records element.

Buy Now
Questions 25

What does the Lightning Component framework provide to developers?

Options:

A.

Support for Classic and Lightning UIs

B.

Prebuilt components that can be reused

C.

Templates to create custom components

D.

Extended governor limits for applications

Buy Now
Questions 26

What are two characteristics related to formulas?

Choose 2 answers

Options:

A.

Formulas are calculated at runtime and are not stored in the database.

B.

Formulas can reference themselves.

C.

Formulas can reference values in related objects.

D.

Fields that are used in a formula field can be deleted or edited without editing the formula.

Buy Now
Questions 27

Universal Containers (UC) uses out-of-the-box order management, that has a Master-Detail relationship between Order and Order Line Item.

UC stores the availability date on each Order Line Item and Orders are only shipped when all of the Order Line Items are available.

Which method should be used to calculate the estimated ship date for an Order?

Options:

A.

Use 2 LATEST formula on each of the latest availability date fields.

B.

Use a CEILING formula on each of the latest availability date fields.

C.

Use @ DAYS formula on each of the availability date fields and a COUNT Roll-Up Summary field on the Order.

D.

Use a MAX Roll-Up Summary field on the latest availability date fields.

Buy Now
Questions 28

A development team wants to use a deployment script to automatically deploy to a sandbox during their development cycles.

Which two tools can they use to run a script that deploys to a sandbox?

Choose 2 answers

Options:

A.

SFDX CLI

B.

Developer Console

C.

Change Sets

D.

Ant Migration Tool

Buy Now
Questions 29

What are two considerations for deploying from a sandbox to production?

Choose 2 answers

Options:

A.

At least 75% of Apex code must be covered by unit tests.

B.

Unit tests must have calls to the System.assert method.

C.

Should deploy during business hours to ensure feedback can be quickly addressed.

D.

All triggers must have at least one line of test coverage.

Buy Now
Questions 30

Which scenario is valid for execution by unit tests?

Options:

A.

Execute anonymous Apex as a different user.

B.

Generate a Visualforce PDF with getcontentaAsPDF ().

C.

Load data from a remote site with a callout.

D.

Set the created date of a record using a system method.

Buy Now
Questions 31

If Apex code executes inside the execute() method of an Apex class when implementing the Batchable interface, which two statements are true regarding governor limits?

Choose 2 answers

Options:

A.

The Apex governor limits are reset for each iteration of the execute () method.

B.

The Apex governor limits cannot be exceeded due to the asynchronaus nature of the transaction.

C.

The Apex governor limits will use the asynchronous limit levels.

D.

The Apex governor limits are omitted while calling the constructor of the Apex class.

Buy Now
Questions 32

Which two characteristics are true for Lightning Web Component custom events?

Choose 2 answers

Options:

A.

Data may be passed in the payload of a custom event using @wire decorated properties.

B.

Data may be passed In the payload of a custom event using a property called detail.

C.

By default a custom event only propagates to its immediate container and to its immediate child component.

D.

By default a custom event only propagates to it’s immediate container.

Buy Now
Questions 33

A developer creates a batch Apex job to update a large number of records, and receives reports of the job timing out and not completing.

What is the first step towards troubleshooting the issue?

Options:

A.

Check the asynchronous job monitoring page to view the job status and logs.

B.

Check the debug logs for the batch job.

C.

Disable the batch job and recreate it with a smaller number of records.

D.

Decrease the batch size to reduce the load on the system.

Buy Now
Questions 34

Universal Containers has a large number of custom applications that were built using a third-party JavaScript framework and exposed using Visualforce pages. The company wants to update these applications to apply styling that resembles the look and feel of Lightning Experience.

What should the developer do to fulfill the business request in the quickest and most effective manner?

Options:

A.

Rewrite all Visualforce pages as Lightning components.

B.

Set the attribute enableLightning to true in the definition.

C.

Enable Available for Lightning Experience, Lightning Communities, and the mobile app on Visualforce pages used by the custom application.

D.

Incorporate the Salesforce Lightning Design System CSS stylesheet Into the JavaScript applications.

Buy Now
Questions 35

What should a developer do to check the code coverage of a class after running all tests?

Options:

A.

View the code coverage percentage for the class using the Overall Code Coverage panel in the Developer Console Tests tab.

B.

View the Class Test Percentage tab on the Apex Class list view in Salesforce Setup.

C.

Select and run the class on the Apex Test Execution page in the Developer Console.

D.

View the Code Coverage column in the list view an the Apex Classes page.

Buy Now
Questions 36

Which code statement includes an Apex method named updateAccounts in the class AccountController for use in a Lightning web component?

Options:

A.

import updateAccounts from "AccountControlles';

B.

import updateAccounts from "Salesforce/apex/AccountController:';

C.

import updateAccounts from "Account@ontroller.updateAccounts';

D.

import updateAccounts from "@salesforce/apex/AccountController.updateAccounts";

Buy Now
Questions 37

A developer wants to get access to the standard price book in the org while writing a test class that covers an OpportunityLineltem trigger.

Which method allows access to the price book?

Options:

A.

Use Test .getStandardPricebookid() to get the standard price book ID.

B.

Use @isTest [SeeAllData=true| and delete the existing standard price book.

C.

Use @Testvisible to allow the test method to see the standard price book.

D.

Use Test. loadData () and a static resource to load a standard price book.

Buy Now
Questions 38

What is the value of the Trigger.old context variable in a before insert trigger?

Options:

A.

An empty list of sObjects

B.

Undefined

C.

null

D.

A list of newly created sObjects without IDs

Buy Now
Questions 39

A developer is alerted to an issue with a custom Apex trigger that is causing records to be duplicated.

What is the most appropriate debugging approach to troubleshoot the issue?

Options:

A.

Review the Historical Event logs to identify the source of the issue.

B.

Add system.debug statements to the code to track the execution flow and identify the issue.

C.

Use the Apex Interactive Debugger to step through the code and identify the issue.

D.

Disable the trigger in production and test to see if the issue still occurs.

Buy Now
Questions 40

A developer created a Lightning web component called statuscomponent to be Inserted into the Account record page.

Which two things should the developer do to make this component available?

Choose 2 answers

Options:

A.

Add lightning_Recordpage to the statuscomponent. js file,

B.

Add lightning RecordPage to the statusComp .js-meta.xml file.

C.

Set is Exposes to true In the statuscomponent.js-meta.xml file.

D.

Add Account to the statusComponent. js-meta.xm1 file.

Buy Now
Questions 41

Which code in a Visualforce page and/or controller might present a security vulnerability?

PDI Question 41

Options:

A.

Option A

B.

Option B

C.

Option C

D.

Option D

Buy Now
Questions 42

A developer is working on a project to import data from an external system into Salesforce. The data contains sensitive information that should not be visible to all users in Salesforce.

What should the developer do to ensure that the data is secure?

Options:

A.

Use a third-party tool to encrypt the sensitive data before importing it into Salesforce.

B.

Use the Apex Data Loader to import the into and write Apex code to handle security and access

control.

C.

Use the Data Import Wizard to import the data arid set up field-level security to restrict access to

sensitive fields.

D.

Use the Salesforce CLI to import the data and set up user permissions to restrict access to sensitive data.

Buy Now
Questions 43

An Opportunity needs to have an amount rolled up from a custom object that is not in a master-detail relationship.

How can this be achieved?

Options:

A.

Write a trigger on the Opportunity object and use tree sorting to sum the amount for all related child objects under the Opportunity.

B.

Use the Streaming API to create real-time roll-up summaries.

C.

Write a trigger on the child object and use an aggregate function to sum the amount for all related child objects under the Opportunity.

D.

Use the Metadata API to create real-time roll-up summaries.

Buy Now
Questions 44

A developer is asked to prevent anyone other than a user with Sales Manager profile from changing the Opportunity Status to Closed Lost if the lost reason is blank.

Which automation allows the developer to satisfy this requirement in the most efficient manner?

Options:

A.

An Apex trigger on the Opportunity object

B.

An error condition formula on a validation rule on Opportunity

C.

A record trigger flow on the Opportunity object

D.

An approval process on the Opportunity object

Buy Now
Questions 45

A developer needs to confirm that a Contact trigger works correctly without changing the organization's data.

What should the developer do to test the Contact trigger?

Options:

A.

Use Deploy from the VSCode IDE co deploy an 'insert Contact' Apex class.

B.

Use the New button on the Salesforce Contacts Tab to create a new Contact record.

C.

Use the Test menu on the Developer Console to run oil test classes for the Contact trigger.

D.

Use the Open Execute Anonymous feature on the Developer Console to run an "insert Contact' DML statement.

Buy Now
Questions 46

A developer wants to mark each Account in a List as either Active or Inactive, based on the value in the LastModified each Account being greater than 90 days in the past.

Which Apex technique should the developer use?

Options:

A.

An if-else statement, with a for loop inside

B.

A witch statement, with a for loop inside

C.

A for loop, with an if or if/else statement inside

D.

A for loop, with a switch statement inside

Buy Now
Questions 47

In the following example, which sharing context will myMethod execute when it is invoked?

PDI Question 47

Options:

A.

Sharing rules will be enforced by the instantiating class.

B.

Sharing rules will be enforced for the running user.

C.

Sharing rules will not be enforced for the running user.

D.

Sharing rules will be inherited from the calling context.

Buy Now
Questions 48

What are two ways for a developer to execute tests in an org?

Choose 2 answers

Options:

A.

Tooling API

B.

Metadata API

C.

Bulk API

D.

Developer Console

Buy Now
Questions 49

The following Apex method is part of the ContactService class that is called from a trigger:

PDI Question 49

How should the developer modify the code to ensure best practices are met?

A)

PDI Question 49

B)

PDI Question 49

C)

PDI Question 49

D)

Options:

A.

Option A

B.

Option B

C.

Option C

D.

Option D

Buy Now
Questions 50

Universal Containers wants to automatically assign new cases to the appropriate support representative based on the case origin. They have created a custom field on the Case object to store the support representative name.

What is the best solution to assign the case to the appropriate support representative?

Options:

A.

Use a trigger on the Case object.

B.

Use a formula field on the Case object.

C.

Use a validation rule on the Case object.

D.

Use an Assignment Flow element.

Buy Now
Questions 51

A developer creates a custom exception as shown below:

public class ParityException extends Exception { }

What are two ways the developer can fire the exception in Apex?

Options:

A.

throw new ParityException ();

B.

throw new parityException ('parity does not match');

C.

new ParityException ();

D.

new ParityException('parity does not match');

Buy Now
Questions 52

A company's engineering department is conducting a month-long test on the scalability of an in-house-developed software that requires a cluster of 100 or more servers. Which of the following models is the best to use?

Options:

A.

PaaS

B.

SaaS

C.

BaaS

D.

laaS

Buy Now
Questions 53

Which statement should be used to allow some of the records in a list of records to be inserted if others fail to be inserted?

Options:

A.

Database. insert (records, true)

B.

insert records

C.

insert (records, false)

D.

Database. insert (records, false)

Buy Now
Questions 54

A team of developers is working on a source-driven project that allows them to work independently, with many different org configurations.

Which type of Salesforce orgs should they use for their development?

Options:

A.

Developer sandboxes.

B.

Full Copy sandboxes

C.

Developer orgs

D.

Scratch orgs

Buy Now
Questions 55

The value of the account type field is not being displayed correctly on the page. Assuming the custom controller is properly referenced on the Visualforce page, what should the developer do to correct the problem?

Options:

A.

Add a getter method for the actType attribute.

B.

Change theAccount attribute to public.

C.

Add with sharing to the custom controller.

D.

Convert theAccount.Type to a String.

Buy Now
Questions 56

Universal Containers wants Opportunities to no longer be editable when it reaches the Closed/Won stage.

Which two strategies can a developer use to accomplish this?

Choose 2 answers

Options:

A.

Use a validation rule.

B.

Use an auto-response rule.

C.

Use a before-save Apex trigger,

D.

Use an automatically launched Approval Process.

Buy Now
Questions 57

A Next Best Action strategy uses an Enhance element that invokes an Apex method to determine a discount level for a Contact, based on a number of factors.

What is the correct definition of the Apex method?

A)

PDI Question 57

B)

PDI Question 57

C)

PDI Question 57

D)

PDI Question 57

Options:

A.

Option A

B.

Option B

C.

Option C

D.

Option D

Buy Now
Questions 58

Universal Containers has a support process that allows users to request support from its engineering team using a custom object,

Engineering Support c.

Users should be able to associate multiple Engineering Support __c records to a single Opportunity record. Additionally, aggregate information

about the Engineering Support _c records should be shown on the Opportunity record.

Which relationship field should be implemented to support these requirements?

Options:

A.

Lookup field from Opportunity to Engineering _support__c

B.

Master-detail field from Engineering Support__c to Opportunity

C.

Master-detail field from Opportunity to Engineering Support__c

D.

Lookup field from Engineering Support __c to Opportunity

Buy Now
Questions 59

Which exception type cannot be caught?

Options:

A.

custom exception

B.

LinkException

C.

NoAccessException

D.

CelloutException

Buy Now
Questions 60

A developer is tasked to perform a security review of the ContactSearch Apex class that exists in the system. Within the class, the developer identifies the following method as a security threat:

ist performSearch (String lastName} [

return Database.query('SELECT Id, FirstName, LastName FROM Contact WHERE LastName Like

s'+lastName+'s'")?;

What are two ways the developer can update the method to prevent a SOQL injection attack?

Choose 2 answers

Options:

A.

Use variable binding and replace the dynamic query with a static SOQL.

B.

Use the sacapeSingleQuotes method to sanitize the parameter before its use.

C.

Use the ¢Readonly annotation and the with sharing keyword on the class.

D.

Use a regular expression on the parameter to remove special characters.

Buy Now
Exam Code: PDI
Exam Name: Salesforce Certified Platform Developer 1 (WI25)
Last Update: Jan 10, 2025
Questions: 200

PDF + Testing Engine

$57.75  $164.99

Testing Engine

$43.75  $124.99
buy now PDI testing engine

PDF (Q&A)

$36.75  $104.99
buy now PDI pdf
dumpsmate guaranteed to pass
24/7 Customer Support

DumpsMate's team of experts is always available to respond your queries on exam preparation. Get professional answers on any topic of the certification syllabus. Our experts will thoroughly satisfy you.

Site Secure

mcafee secure

TESTED 18 Jan 2025