Salesforce PDI Online Practice
Questions and Exam Preparation
PDI Exam Details
Exam Code
:PDI
Exam Name
:Salesforce Certification for Platform Developer I (Plat-Dev-201)
Certification
:Salesforce Certifications
Vendor
:Salesforce
Total Questions
:270 Q&As
Last Updated
:May 25, 2026
Salesforce PDI Online Questions &
Answers
Question 81:
What should a developer use to obtain the Id and Name of all the Leads, Accounts, and Contacts that have the company name "Universal Containers?
A. FIND 'Universal Containers' IN CompanyName FIELDSRETURNING Lead(Id, Name), Account(Id, Name), Contact(Id, Name) B. SELECT Lead.Id, Lead.Name, Account.Id, Account.Name, Contact.Id, Contact.NameFROM Lead, Account, ContactWHERE CompanyName = 'Universal Containers' C. FIND 'Universal Containers' IN Name FIELDSRETURNING Lead(Id, Name), Account(Id, Name), Contact(Id, Name) D. SELECT Lead(Id, Name), Account(Id, Name), Contact(Id, Name)FROM Lead, Account, ContactWHERE Name = 'Universal Containers'
A. FIND 'Universal Containers' IN CompanyName FIELDSRETURNING Lead(Id, Name), Account(Id, Name), Contact(Id, Name)
Explanation
The correct choice is the SOSL statement because the requirement is to search for the same text value across multiple objects (Lead, Account, and Contact) and return only specific fields. SOSL is designed for cross-object text searches, whereas SOQL cannot query multiple unrelated objects in a single statement.
Question 82:
A developer created a weather app that contains multiple Lightning web components.
One of the components, called Toggle, has a toggle for Fahrenheit or Celsius units. Another component, called Temperature, displays the current temperature in the unit selected in the Toggle component
When a user toggles from Fahrenheit to Celsius or vice versa in the Toggle component, the information must be sent to the Temperature component so the temperature can be converted and displayed.
What is the recommend way to accomplish this?
A. Create a custom event to handle the communicate between the components. B. Use Lightning Message Service to communicate between the component. C. Use Lightning Message Service to communicate between the components. D. The Toggle component should call a method in the Temperature component.
A. Create a custom event to handle the communicate between the components.
Explanation
Question 83:
A developer needs to expose an Apex method to a Lightning web component so it can be called from JavaScript.
Which annotation is required?
A. @AuraEnabled B. @InvocableMethod C. @RemoteAction D. @TestVisible
A. @AuraEnabled
Explanation
The @AuraEnabled annotation allows Apex methods and properties to be accessed by Lightning components, including Lightning web components. When this annotation is applied, the method becomes callable from client-side JavaScript, provided it meets other requirements such as being static and having supported parameter types. @InvocableMethod is used for Flow integrations, @RemoteAction is intended for Visualforce JavaScript remoting, and @TestVisible is used to expose private members to test classes, not to UI components.
Question 84:
A developer is tasked with performing a complex validation using Apex as part of advanced business logic. certain criteria are met for a PurchaseOrder, the developer must throw a custom exception.
What is the correct way for the developer to declare a class that can be used as an exception?
A. public class PurchaseOrderException implements Exception () B. public class PurchaseOrderException extends Exception () C. public class PurchaseOrder implements Exception () D. public class PurchaseOrder extends Exception ()
B. public class PurchaseOrderException extends Exception ()
Explanation
Question 85:
What can be easily developed using the Lightning Component framework?
A. Salesforce Classic user interface pages B. Lightning Pages C. Customized JavaScript buttons D. Salesforce integrations
B. Lightning Pages
Explanation
Why Lightning Pages?
The Lightning Component framework is designed for building responsive Lightning Pages.
Allows for dynamic and modular development.
Why Not Other Options?
A: Salesforce Classic does not support Lightning Components.
C: JavaScript buttons are replaced by Quick Actions in Lightning Experience.
D: While integrations are possible, the framework is not primarily used for integrations.
A developer needs to debug Apex code executed by a specific user.
What should be configured?
A. Debug level only B. Trace flag for the user C. Workflow debug logs D. Apex exception email
B. Trace flag for the user
Explanation
To capture debug logs for Apex code executed by a specific user, a trace flag must be configured for that user. Trace flags determine which operations are logged, the logging level, and the duration of logging. Without a trace flag, Salesforce does not generate debug logs for the user's activity. Debug levels define the verbosity of logs but must be associated with a trace flag to take effect. Workflow debug logs and exception emails do not provide detailed Apex execution information.
Question 87:
What are two best practices when it comes to Lightning Web Component events?
A. Use event.target to communicate data to elements that aren't in the same shadow tree. B. Use events configured with bubbles: false and composed:false. C. Use CustomEvent to pass data from a child to a parent component. D. Use event.detail to communicate data to elements in the same shadow tree
A. Use event.target to communicate data to elements that aren't in the same shadow tree. C. Use CustomEvent to pass data from a child to a parent component.
Explanation
Question 88:
A developer wants to run logic asynchronously and allow chaining of jobs.
Which Apex feature should be used?
A. @future method B. Batch Apex C. Queueable Apex D. Scheduled Apex
C. Queueable Apex
Explanation
Queueable Apex provides asynchronous execution with the added benefit of job chaining, allowing one queueable job to enqueue another. This makes it more flexible than @future methods, which do not support chaining or complex job management. Batch Apex is designed for large data volumes rather than job orchestration, and Scheduled Apex focuses on timing rather than asynchronous chaining. Queueable Apex also supports callouts, making it suitable for integrations and complex processing.
Question 89:
What is a benefit of developing applications
A. Enforced unit testing and code coverage best practices B. Access to predefined computing resources C. Preconfigured storage for big data D. Unlimited processing power and memory
A. Enforced unit testing and code coverage best practices
Explanation
Salesforce enforces unit testing and minimum code coverage requirements for all Apex code before deployment to production, which ensures higher code quality and adherence to best practices.
Question 90:
A company has been adding data to Salesforce and has not done a good Job of limiting the creation of duplicate Lead records. The developer is considering writing an Apex process to identify duplicates and merge the records together.
Which two statements are valid considerations when using merged? Choose 2 answers
A. The field values on the master record are overwritten by the records being merged. B. Merge is supported with accounts, contacts, cases, and leads. C. External ID fields can be used with the merge method. D. The merge method allows up to three records, including the master and two additional records with the same sObject type, to be merged into the master record.
B. Merge is supported with accounts, contacts, cases, and leads. D. The merge method allows up to three records, including the master and two additional records with the same sObject type, to be merged into the master record.
Nowadays, the certification exams become more and more important and required by more and more
enterprises when applying for a job. But how to prepare for the exam effectively? How to prepare
for the exam in a short time with less efforts? How to get a ideal result and how to find the
most reliable resources? Here on Vcedump.com, you will find all the answers.
Vcedump.com provide not only Salesforce exam questions,
answers and explanations but also complete assistance on your exam preparation and certification
application. If you are confused on your PDI exam preparations
and Salesforce certification application, do not hesitate to visit our
Vcedump.com to find your solutions here.