Salesforce Certified Platform Developer Plat-Dev-201 Exam Questions

Page: 1 / 14
Total 204 questions
Question 1

Universal Containers (UC) uses a custom object called Vendor. The Vendor custom object has a master-detail relationship with the standard Account object.

Based on some internal discussions, the UC administrator tried to change the master-detail relationship to a lookup relationship, but was not able to do so.

What is a possible reason that this change was not permitted?



Answer : B

Master-detail relationships allow roll-up summary fields to aggregate data from child records. If a roll-up summary field exists on the Account object, the relationship cannot be changed to a lookup because lookup relationships do not support roll-up fields.

Why not other options?

A: Null values in the Vendor records do not prevent the change.

C: Custom fields can have their types changed as long as dependencies like roll-up fields are not present.

D: Organization-wide defaults do not affect the ability to change relationships.

:

Salesforce Master-Detail Relationships and Roll-Up Summary Fields


Question 2

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?



Answer : D

The quickest way to make Visualforce pages styled like Lightning Experience is by incorporating SLDS. This provides consistent styling without rewriting the applications.

Why not other options?

A: Rewriting all Visualforce pages as Lightning components is time-consuming and not efficient.

B: There is no attributeenableLightningin Visualforce.

C: Enabling Lightning Experience compatibility does not apply styling automatically.

:

Salesforce Lightning Design System (SLDS)


Question 3

Universal Containers (UC) processes orders in Salesforce in a custom object, Order__c. They also allow sales reps to upload CSV files with thousands of orders at a time.

A developer is tasked with integrating orders placed in Salesforce with UC's enterprise resource planning (ERP) system.

After the status for an Order__c is first set to 'Placed', the order information must be sent to a REST endpoint in the ERP system that can

process one order at a time.

What should the developer implement to accomplish this?



Answer : A

Why Queueable Class?

Queueable Apex supports callouts and allows chaining to process one record at a time efficiently.

The trigger detects when theOrder__cstatus changes to 'Placed' and enqueues the Queueable class to perform the callout.

Why Not Other Options?

B . Batchable class: Batch jobs are ideal for bulk processing but not suited for single REST callouts.

C . Flow with invocable method: Flows are less efficient and limited in handling callouts for large-scale operations.

D . @future method: While it supports asynchronous callouts, it does not allow chaining, making Queueable more suitable.


Question 4

How is a controller and extension specified for a custom object named "Notice" on a Visualforce page?



Answer : D

In Visualforce, to specify a standard controller for a custom object, the syntax iscontroller='ObjectName__c'.

To add custom functionality, you can use anextensionsattribute to include a controller extension.

Why not other options?

A: The correct syntax iscontroller, notstandardController, for custom objects.

BandC: These are syntactically incorrect.

:

Visualforce Pages Documentation


Question 5

Which two are best practices when it comes to Aura component and application event handling?

Choose 2 answers



Answer : B, D

Option B: Reusing event logic in the helper ensures cleaner and reusable code.

Option D: Handling low-level events in handlers and re-firing them as higher-level events allows for better abstraction and modularity.

:Aura Event Handling Documentation


Question 6

How should a developer write unit tests for a private method in an Apex class?



Answer : D

The@TestVisibleannotation allows private methods or variables to be accessed in test classes. This ensures that the private method can be adequately tested without changing its access modifier.


Below is the formatted response for the provided question, adhering to the specified format and requirements. The question falls under the Salesforce Platform and Declarative Features topic, as it involves securing SOQL queries against injection vulnerabilities in the context of Visualforce, which is a key concept in the Salesforce Platform Developer I certification. The answer is based on official Salesforce Platform Developer I documentation, with a comprehensive explanation and references to relevant Salesforce documentation. Since the question asks for two correct answers, the response will identify both and explain why they are safe, as well as why the others are not.

Question 7

Since Aura application events follow the traditional publish-subscribe model, which method is used to fire an event?



Answer : A

Option A: Thefire()method is used to publish Aura application events in the traditional publish-subscribe model.

Not Suitable:

Option B:sendEvent()is not a valid method for Aura events.

Option C:FireEvent()does not exist.

Option D:emit()is not part of the Aura event framework.

:Aura Application Events


Page:    1 / 14   
Total 204 questions