Updated PDF (New 2024) Actual Salesforce PDI Exam Questions
Verified PDI Exam Dumps PDF [2024] Access using Exams4sures
NEW QUESTION # 23
A developer receives an error when trying to call a global server-side method using the @remoteAction decorator.
How can the developer resolve the error?
- A. A Decorate the server-side method with (static=true).
- B. Decorate the server-side method with (static=false).
- C. Add static to the server-side method signature.
- D. Change the function signature to be private static.
Answer: C
NEW QUESTION # 24
The Salesforce Administrator created a custom picklist field, Account_status_c, on the a Account object. This picklist has possible values of Inactive'' and Active?
As part of a new business process, management wants to ensure an opportunity record is created only for Accounts marked as "Active". A developer is asked to implement this business requirement.
Which two automation tools should be used to fulfill the business need?
Choose 2 answers
- A. Approval Process
- B. Salesforce Flow
- C. Process Builder
- D. Workflow Rules
Answer: B
NEW QUESTION # 25
A developer needs to create a baseline set of data (Accounts, Contacts, Products, Assets) for an entire suite of tests allowing them to test independent requirements various types of Salesforce Cases. Which approach can efficiently generate the required data for each unit test?
- A. Create a mock using Stub API
- B. Create test data before test.startTest() in the test unit.
- C. Use @TestSetup with a void method
- D. Add @IsTest(seeAllData=true) at the start of the unit test class
Answer: C
NEW QUESTION # 26
Which two practices should be used for processing records in a trigger? Choose 2 answers
- A. Use a Set to ensure unique values in a query filter
- B. Use (callout=true) to update an external system
- C. Use a Map to reduce the number of SOQL calls
- D. Use @future methods to handle DML operations.
Answer: A,C
NEW QUESTION # 27
Universal Container(UC) wants to lower its shipping cost while making the shipping process more efficient. The Distribution Officer advises UC to implement global addresses to allow multiple Accounts to share a default pickup address. The Developer is tasked to create the supporting object and relationship for this business requirement and uses the Setup Menu to create a custom object called "Global Address". Which field should the developer ad to create the most efficient model that supports the business need?
- A. Add a Master-Detail field on the Account object to the Global Address object
- B. Add a Master-Detail field on the Global Address object to the Account object.
- C. Add a Lookup field on the Account object to the Global Address object.
- D. Add a Lookup field on the Global Address object to the Account object
Answer: B
NEW QUESTION # 28
Universal Containers (UC) has an integration with its Accounting system that creates tens of thousands of Orders inside of Salesforce in a nightly batch. UC wants to add automaton that can attempt to match Leads and Contacts to these Orders using the Email Address field on the insert. UC is concerned about the performance of the automation with a large data volume. Which tool should UC use to automate this process?
- A. Process Builder with an Autolaunched Flow
- B. Process Builder
- C. Workflow Rules
- D. Apex
Answer: D
NEW QUESTION # 29
Which three data types can a SOQL query return? Choose 3 answers
- A. Long
- B. List
- C. Integer
- D. sObject
Answer: B,C,D
NEW QUESTION # 30
Universal Containers (UC) decided it will not to send emails to support personnel directly from Salesforce in the event that an unhandled exception occurs. Instead, UC wants an external system be notified of the error.
What is the appropriate publish/subscribe logic to meet these requirements?
- A. Have the external system subscribe to the BatchApexError event, no publishing is necessary.
- B. Publish the error event using the addError() method and have the external system subscribe to the event using CometD.
- C. Publish the error event using the addError() method and write a trigger to subscribe to the event and notify the external system.
- D. Publish the error event using the Eventbus.publish() method and have the external system subscribe to the event using CometD.
Answer: D
NEW QUESTION # 31
what are the methods used to show input in classic and lightning ?
Answer:
Explanation:
Use visualforce page in classic and lightning component in lightning
NEW QUESTION # 32
n org has an existing flow that creates an Opportunity with an Update Records element. A developer must update the flow to aiso create a 'Contact and store the created Contact's 1D on the Opportunity.
Which update must the developer make in the flow?
- 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.
Answer: C
NEW QUESTION # 33
Which two operations can be performed using a formula field? Choose 2 answers
- A. Calculating a score on a Lead based on the information from another field
- B. Displaying an Image based on the Opportunity Amount
- C. Triggering a Process Builder
- D. Displaying the last four digits of an encrypted Social Security number
Answer: A,B
NEW QUESTION # 34
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.
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
- A. Move the DML that saves opportunities outside the for loop.
- B. Query for existing opportunities outside the for loop.
- C. Check if all the required fields for Opportunity are being added on creation.
- D. Use Database.query to query the opportunities.
Answer: A,B
NEW QUESTION # 35
Which feature should a developer use to update an inventory count on related Product records when the status of an Order is modified to indicate it is fulfilled?
- A. Process Builder process
- B. Lightning component
- C. Workflow rule
- D. Visualforce page
Answer: A
NEW QUESTION # 36
D18912E1457D5D1DDCBD40AB3BF70D5D
A developer must create a ShippingCalculator class that cannot be instantiated and must include a working default implementation of a calculate method, that sub-classes can override.
What is the correct implementation of the ShippingCalculator class?
- A. Option C
- B. Option B
- C. Option A
- D. Option D
Answer: B
NEW QUESTION # 37
When using SalesforceDX, what does a developer need to enable to create and manage scratch orgs?
- A. Sandbox
- B. Production
- C. Dev Hub
- D. Environment Hub
Answer: C
Explanation:
https://developer.salesforce.com/docs/atlas.en-us.sfdx_dev.meta/sfdx_dev/sfdx_dev_scratch_orgs.htm
NEW QUESTION # 38
The following code snippet is executed by a Lightning web component in an environment with more than
2,000 lead records:
Which governor limit will likely be exceeded within the Apex transaction?
- A. Total number of SOQL queries issued
- B. Total number of records retrieved by SOQL queries
- C. Total number of records processed as a result of DML statements
- D. Total number of DML statement issued
Answer: B
NEW QUESTION # 39
A custom picklist field, Food_Preference__c, exist on a custom object. The picklist contains the following options: 'Vegan','Kosher','No Preference'. The developer must ensure a value is populated every time a record is created or updated. What is the most efficient way to ensure a value is selected every time a record is saved?
- A. Set "Use the first value in the list as the default value" as True.
- B. Mark the field as Required on the object's page layout.
- C. Mark the field as Required on the field definition.
- D. Set a validation rule to enforce a value is selected.
Answer: C
NEW QUESTION # 40
A developer must create a ShippingCalculator class that cannot be instantiated and must include a working default implementation of a calculate method, that sub-classes can override. What is the correct implementation of the ShippingCalculator class?
- A. Public abstract class ShippingCalculator {
public virtual void calculate() { /*implementation*/ }
} - B. Public abstract class ShippingCalculator {
public abstract calculate() { /*implementation*/ }
} - C. Public abstract class ShippingCalculator {
public void calculate() { /*implementation*/ }
} - D. Public abstract class ShippingCalculator {
public override calculate() { /*implementation*/ }
}
Answer: A
Explanation:
the extending class can override the existing virtual methods by using the override keyword in the method definition. Overriding a virtual method allows you to provide a different implementation for an existing method https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_classes_extending.htm
NEW QUESTION # 41
How many accounts will be inserted by the following block ofcode? for(Integer i = 0 ; i < 500; i++) { Account a = new Account(Name='New Account ' + i); insert a; }
- A. 0
- B. 1
- C. 2
- D. 3
Answer: B
NEW QUESTION # 42
Which two platform features align to the Controller portion of MVC architecture? (Choose two.)
- A. Date fields
- B. Process Builder actions
- C. Standard objects
- D. Workflow rules
Answer: B,D
NEW QUESTION # 43
Which annotation exposes an Apex class as a RESTful web service?
- A. @RestResource
- B. @AuraEnabled
- C. @Httplnvocable
- D. @Remote Action
Answer: B
NEW QUESTION # 44
......
Try Best PDI Exam Questions from Training Expert Exams4sures: https://www.exams4sures.com/Salesforce/PDI-practice-exam-dumps.html
Practice Examples and Dumps & Tips for 2024 Latest PDI Valid Tests Dumps: https://drive.google.com/open?id=1rrJH0DE0n2-ZJcQD2jp_6q6vlk28xmmH