KEMBAR78
Salesforce Dumps pd1 | PDF | Software Development | Method (Computer Programming)
0% found this document useful (0 votes)
2K views83 pages

Salesforce Dumps pd1

The document contains a series of multiple-choice questions aimed at assessing knowledge of Salesforce development practices, including Apex, Lightning components, and Flow Builder. Key topics include testing methods, data validation, governor limits, and security practices. The questions are designed for developers to demonstrate their understanding of best practices and functionality within the Salesforce platform.

Uploaded by

debjanidas6464
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2K views83 pages

Salesforce Dumps pd1

The document contains a series of multiple-choice questions aimed at assessing knowledge of Salesforce development practices, including Apex, Lightning components, and Flow Builder. Key topics include testing methods, data validation, governor limits, and security practices. The questions are designed for developers to demonstrate their understanding of best practices and functionality within the Salesforce platform.

Uploaded by

debjanidas6464
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 83

SET1

1 . While writing an Apex class, a developer wants to make sure that all functionality being developed
is handled as specified by the requirements.

Which approach should the developer use to be sure that the Apex class is working according to
specifications?

A. Include a try/catch block to the Apex class.

B. Create a test class to execute the business logic and run the test in the Developer Console.

C. Include a savepoint and database.rollback().

D. Run the code in an Execute Anonymous block in the Developer Console.

2 . A developer needs to have records with specific field values in order to test a new Apex class.

What should the developer do to ensure the data is available to the test?

A. Use SOQL to query the org for the required data.

B. Use Anonymous Apex to create the required data.

C. Use Test.loadData() and reference a CSV file in a static resource.

D. Use Test.loadData() and reference a IS0N file in Documents

3 . 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?
A. insert (records, false)
B. Database.insert(records, false)
C. Database.insert(records, true)
D. insert records

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

A. By providing code review standards and processes

B. By providing device awareness for mobile and desktops

C. By providing change history and version control

D. By providing an Agile process with default steps


5 . How can a developer check the test coverage of active Process Builder and Flows deploying them
in a Changing Set?

A. Use the Flow properties page.

B. Use the code Coverage Setup page

C. Use SOQL and the Tooling API

D. Use the Apex testresult class

6 . 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 two.)

A. Set true to the statusComponent.js-meta.xml file.


B. Add lightning_RecordPage to the statusComponent.js file.
C. Add lightning_RecordPage to the statusComponent.js-meta.xml file.
D. Add Account to the statusComponent.js-meta.xml file.

7 . Universal Containers recently transitioned from Classic to Lightning Experience.


One of its business processes requires certain values from the Opportunity object to be sent via an
HTTP REST callout to its external order management system based on a user-initiated action on the
Opportunity detail page. Example values are as follows:
* Name
* Amount
* Account
Which two methods should the developer implement to fulfill the business requirement? (Choose
two.)
A.Create a Visualforce page that performs the HTTP REST callout, and use a Visualforce quick action
to expose the component on the Opportunity detail page.

B.Create a Process Builder on the Opportunity object that executes an Apex immediate action to
perform the HTTP REST callout whenever the Opportunity is updated.

C.Create a Lightning component that performs the HTTP REST callout, and use a Lightning Action to
expose the component on the Opportunity detail page.

D. Create an after update trigger on the Opportunity object that calls a helper method using
@Future(Callout=true) to perform the HTTP REST callout.

8 . Universal Containers wants to ensure that all new leads created ni the system have a valid email
address. They have already created a validation rule to enforce this requirement, but want ot add an
additional layer of validation using automation.
What would be the best solution for this requirement?
A. Submit a REST API Callout with a JSON payload and validate the fields on a third party system
B. Use an Approval Process to enforce the completion of a valid email address using an outbound
message action.
C. Use a before-save Apex trigger on the Lead object to validate the email address and display an
error message if it is invalid
D. Use a custom Lightning Web component to make a callout to validate the fields on a third party
system.
9. An Apex method, getAccounts, that returns a List of Accounts given a searchTerm, is available for
Lightning Web components to use.
What is the correct definition of a Lightning Web component property that uses the getAccounts
method?

Ans: option A

10. Refer to the following Apex code:

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


A. 0
B. 1
C. 2
D. 3

11 . 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?

A. Add custom controller attributes to display the message.


B. Use a try/catch with a custom exception class.
C. Include <apex:messages> on the Visualforce page.
D. Perform the DML using the Database.upsert() method.

12 . A developer has an integer variable called maxAttempts. The developer needs to ensure that
once maxAttempts is initialized, it preserves its value for the length of the Apex transaction; while
being able to share the variable's state between trigger executions.
How should the developer declare maxAttempts to meet these requirements?
A. Declare maxAttempts as a private static variable on a helper class.
B. Declare maxAttempts as a variable on a helper class.
C. Declare maxAttempts as a member variable on the trigger definition.
D. Declare maxAttempts as a constant using the static and final keywords.

13 . Universal Containers has an order system that uses an Order Number to identify an order for
customers and service agents. Order records will be imported into Salesforce.
How should the Order Number field be defined in Salesforce?
A. Direct Lookup
B. External ID and Unique
C. Lookup
D. Indirect Lookup

14 . A developer created a trigger on the Account object. While testing the trigger, the developer
sees the error message 'Maximum trigger depth exceeded'.
What could be the possible causes?
A. the developer does not have the correct user permission.
B. The trigger is getting executed multiple times.
C.The trigger does not have sufficient code coverage.
D.The trigger is too long and should be refactored into a helper class.

15 . A developer is asked to write helper methods that create test data for unit tests.
01: public TestUtils {
02:
03: public static Account createAccount() {
04: Account act= new Account();
05: //...set some fields on acct...
06: return act;
07: }
08: //...other methods...
09: }
What should be changed in the TestUtils class so that its methods are only usable by unit test
methods?

A. Add @IsTest above line 01.

B. Change public to private on line 01

C. Remove static from line 03.

D. Add @IsTest above line 02.


16 . 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 DML statements issued
C. Total number of records processed as a result of DML statements
D. Total number of records retrieved by SOQL queries

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

A. <apex: outputField value = "{!ctrl.userInput}" >


B. <apex outputText value = "{!$CurrentPage.parameters.userInput}">
C. <apex:outputText escape = "false" value = "{!$CurrentPage.parameters.userInput}">
D. <apex:outputField escape-"false" value = "{!ctrl.userInput}" >

18 . What are two ways for a developer to execute tests in an org? (Choose two.)
A. Tooling API
B. Developer Console
C. Metadata API
D. Bulk API

19 . A software company is using Salesforce to track the companies they sell their software to in the
Account object. They also use Salesforce to track bugs in their software with a custom object,
Bug__c.
As part of a process improvement initiative, they want to be able to report on which companies have
reported which bugs. Each company should be able to report multiple bugs and bugs can also be
reported by multiple companies.

What is needed to allow this reporting?


A .Roll-up summary field of Bug__c on Account
B .Junction object between Bug__c and Account
C .Lookup field on Bug__c to Account
D .Master-detail field on Bug__c to Account

20. What are three characteristics of change set deployments? (Choose three.)
A. Change sets can deploy custom settings data.
B. Change sets can only be used between related organizations.
C. Deployment is done in a one-way, single transaction.
D. Sending a change set between two orgs requires a deployment connection.
E. Change sets can be used to transfer records.
21 . A developer deployed a trigger to update the status__c of Assets related to an Account when the
Account''s status changes and a nightly integration that updates Accounts in bulk has started to fail
with limit failures.

What should the developer change about the code to address the failure while still having the code
update all of the Assets correctly?
A Change the gerAssetsToUpdac= method to process all Accounts in one call and call it outside of the for loop
that starts on line 03.

B Add a LIMIT clause to the SOQL query on line 16 to limit the number of Assets queried for an Account.

C Move all of the logic to a Queueable class that queries for and updates the Assets and call it from the trigger.

D Add List<Asset> assets = [SELECT Id, Status__c FROM Asset WHERE AccountId = :acctId] to line 14 and iterate
over the assets list in the for loop on line 15.

22 . A developer is tasked with building a custom Lightning web component to collect Contact information.
The form will be shared among many different types of users in the org. There are security requirements that
only certain fields should be edited and viewed by certain groups of users.

What should the developer use in their Lightning Web Component to support the security requirements?
A. force-input-field
B. ui-input-field
C. aura-input-field
D. lightning-input-field

23 . Which three Salesforce resources can be accessed from a Lightning web component' (Choose 3
answers)
A. Third-party web components
B. Content asset files
C. All external libraries
D. SVG resources
E. Static resources
24 . 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 the user?
A. ●Share the Case_Defect_c record.
B. ●Share the parent Defect_c record.
C. ●Share the parent Case record.
D. ●Share the parent Case and Defect_c records.

25 . In terms of the MVC paradigm, what are two advantages of implementing the layer of a
Salesforce application using Aura Component-based development over Visualforce?
( Choose 2 answers)

A. Self-contained and reusable units of an application


B. Rich component ecosystem
C. Automatic code generation
D. Server-side run-time debugging

26 . 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
additional information?
A. @InvocableMethod(Label='additional Info')
public ContactInfo(Id contactId)
{ /implementation/ }

B. @InvocableMethod(label='Additional Info')
public List<ContactInfo> getInfo(List<Id> contactIds)
{ /implementation/ }

C. @invocableMethod(label)='Additional Info')
public static List<ContactInfo> getInfo(List<Id> contactIds)
{ /Implementation/ }

D. @InvocableMethod(label='additional Info')
public static ContactInfo getInfo(Id contactId)
{ /implementation/ }

27 . Which code displays the contents of a Visualforce page as a PDF?


A.<apex:page contentType="pdf">
B.<apex:page rendersAs="application/pdf">
C.<apex:page contentType="application/pdf">
D.<apex:page renderAs="pdf">

28 . A developer is creating a Lightning web component to show a list of sales records.The Sales
Representative user should be able to see the commission field on each record. The Sales Assistant
user should be able to see all fields on the record except the commission field.

How should this be enforced so that the component works for both users without showing any
errors?

A. Use Lightning Data Service to get the collection of sales records.


B. use WITH SECURITY_ENFORCED in the SOQL that fetches the data for the component.
C. Use Lightning Locker Service to enforce sharing rules and field-level security.
D. Use Security.stripInaccessible to remove fields inaccessible to the current user.

29 . Which annotation should a developer use on an Apex method to make it available to be wired to
a property in a Lightning web component?

A. @RemoteAction(cacheable=true)
B. @AuraEnabled
C. @RemoteAction
D. @AuraEnabled(cacheable=true)

30 . What are two use cases for executing Anonymous Apex code? Choose 2 answers

A . To delete 15,000 inactive Accounts In a single transaction after a deployment


B . To schedule an Apex class to run periodically
C . To run a batch Apex class to update all Contacts
D . To add unit test code coverage to an org

31 . Consider the following code snippet for a Visualforce page that is launched using a Custom
Button on the Account detail page layout.
<apex:page standardController-"Account">

<!-- additional Ul elements -->

<apex:commandButton action-"{!save)" value-"Save"/>

<apex:page>
When the Save button is pressed the developer must perform a complex validation that involves
multiple objects and, upon success, redirect the user to another Visualforce page.
What can the developer use to meet this business requirement?
B. Controller extensions

32. A developer considers the following snippet of code:


Boolean isOK;
integer x;
String theString = 'Hello';
if (isOK == false && theString == 'Hello') {
x = 1;
} else if (isOK == true && theString =='Hello') {
x = 2;
} else if (isOK != null && theString == 'Hello') {
x = 3;
} else {
x = 4;
}
Based on this code, what is the value of x?

A. 4
B. 2
C. 3
D. 1

33 . What is a considerations for running a flow in debug mode?


A. When debugging a schedule-triggered flow, the flow starts only for one record.

B. Clicking Pause allows an element to be replaced in the low.

C. DML operations will be rolled back when the debugging ends.

D. Callouts to external systems are not executed when debugging a flow

34 . What are two ways a developer can get the status of an enquered job for a class that queueable
interface? ( Choose 2 answers)

A . View the apex status Page


B . View the apex flex Queue
C . View the apex Jobs page
D . Query the AsyncApexJobe object

35 . What is an example of a polymorphic lookup field in Salesforce?


A. The WhatId field on the standard Event object
B. The ParentId field on the standard Account object
C. A custom field, Link__c, on the standard Contact object that looks up to an Account or a Campaign
D. The LeadId and ContactId fields on the standard Campaign Member object.

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

public static void setBusinessUnitToEMEA(Contact thisContact){


thisContact.Business_Unit__c = "EMEA" ;
update thisContact;
}

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

A. Public void setBusinessUnitToEMEA(List<Contact> contatcs){


contacts[0].Business_Unit__c = 'EMEA' ;
update contacts[0];
}
B. Public static void setBusinessUnitToEMEA(Contact thisContact){
List<Contact> contacts = new List<Contact>();
contacts.add(thisContact.Business_Unit__c = 'EMEA');
update contacts;
}

C. Public static void setBusinessUnitToEMEA(List<Contact> contacts){


for(Contact thisContact : contacts){
thisContact.Business_Unit__c = 'EMEA' ;
update contacts[0];
}
}

D. Public static void setBusinessUnitToEMEA(List<Contact> contacts){


for(Contact thisContact : contacts) {
thisContact.Business_Unit__c = 'EMEA' ;
}
update contacts;
}

37 . Given the following Anonymous Block:

What should a developer consider for an environment that has over 10,000 Case records?

 A. The transaction will succeed and changes will be committed.


 B. The transaction will fail due to exceeding the governor limit.
 C. The try/catch block will handle any DML exceptions thrown.
 D. The try/catch block will handle exceptions thrown by governor limits.

38 . Universal Containess wants Opportunities to no longer be editable when its reaches the
Closed/Won stage.
Which two strategies can a developer use to accomplish this? (Choose 2 answers)

A. Use an auto response rule.


B. Use a validation rule.
C. Use an automatically launched Approval Process.
D. Use a before-save Apex trigger.
39 . Cloud Kicks Fitness, an ISV Salesforce partner, is developing a managed package application. One
of the application modules allows the user to calculate body fat using the Apex class, BodyFat, and its
method, calculateBodyFat(). The product owner wants to ensure this method is accessible by the
consumer of the application when developing customizations outside the ISV's package namespace.
Which approach should a developer take to ensure calculateBodyFat() is accessible outside the
package namespace?
A. Declare the class and method using the public access modifier.
B. Declare the class as global and use the public access modifier on the method.
C. Declare the class as public and use the global access modifier on the method.
D. Declare the class and method using the global access modifier.

40 . A developer completed modifications to a customized feature that is comprised of two


elements:
* Apex trigger
* Trigger handler Apex class
What are two factors that the developer must take into account to properly deploy the modification
to the production environment? (Choose two.)
A. Apex classes must have at least 75% code coverage org-wide.
B. At least one line of code must be executed for the Apex trigger.
C. All methods in the test classes must use @isTest.
D. Test methods must be declared with the testMethod keyword.

41 . A developer created a child Lightning web component nested inside a parent Lightning web
component. The parent component needs to pass a string value to the child component.

In which two ways can this be accomplished? (Choose two.)

A. The parent component can use a custom event to pass the data to the child component.
B. The parent component can invoke a public method in the child component.
C. The parent component can use a public property to pass the data to the child component.
D. The parent component can use the Apex controller class to send data to the child component.

42 . What are two benefits of using declarative customizations over code?(Choose 2 answers)
A. Declarative customizations automatically update with each Salesforce release.
B. Declarative customizations automatically generate test classes.
C. Declarative customizations cannot generate run time errors.
D. Declarative customizations generally require less maintenance

43 . A developer must provide custom user interfaces when users edit a Contact in either Salesforce
Classic or Lightning Experience.
What should the developer use to override the Contact's Edit button and provide this functionality?

A. A Lightning page in Salesforce Classic and a Visualforce page in Lightning Experience


B. A Visualforce page in Salesforce Classic and a Lightning page in Lightning Experience
C. A Lightning component in Salesforce Classic and a Lightning component in Lightning Experience
D. A Visualforce page in Salesforce Classic and a Lightning componenet in Lightning Experience
44 . Universal Containers stores the availability date on each Line Item of an Order and Orders are
only shipped when all of the Line Items are available. Which method should be used to calculate the
estimated ship date for an Order?

A. Use a Max Roll-Up Summary field on 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 LATEST formula on each of the latest availability date fields.

45 . Which two are phases in the Salesforce Application Event propagation framework? (Choose two.)
A. Bubble
B. Default
C. Control
D. Emit

46 . 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 Lookup field on the Account object to the Global Address object.

B. Add a Lookup field on the Global Address object to the Account object

C. Add a Master-Detail field on the Account object to the Global Address object

D. Add a Master-Detail field on the Global Address object to the Account object.

47 . Which statement generates a list of Leads and Contacts that have a field with the phrase
'ACME'?
A. List <sObject> searchList = (FIND "ACME" IN ALL FIELDS RETURNING Contact, Lead);

B. Map <sObject> searchList = (FIND "ACME" IN ALL FIELDS RETURNING Contact, Lead);

C. List<List <sObject>> searchList = (FIND "ACME" IN ALL FIELDS RETURNING Contact, Lead);

D. List<List < sObject>> searchList = (SELECT Name, ID FROM Contact, Lead WHERE Name like
'%ACME%');

48 . Universal Containers wants to back up all of the data and attachments in its Salesforce org once
month. Which approach should a developer use to meet this requirement?
A. Use the Data Loader command line.
B. Create a Schedulable Apex class.
C. Schedule a report.
D. Define a Data Export scheduled job.

49 . A developer identifies the following triggers on the Expense__c object:


deteleExpense,
applyDefaultsToExpense,
validateExpenseUpdate;
The triggers process before delete, before insert, and before update events respectively.
Which two techniques should the developer implement to ensure trigger best practices are
followed? (Choose two.)

A. Unify the before insert and before update triggers and use Process Builder for the delete action.
B. Create helper classes to execute the appropriate logic when a record is saved.
C. Maintain all three triggers on the Expense__c object, but move the Apex logic out of the trigger
definition.
D. Unify all three triggers in a single trigger on the Expense__c object that includes all events.

50 . A developer must create a DrawList class that provides capabilities defined in the Sortable and
Drawable interfaces.

Which is the correct implementation?


A.

B. ANSWER

C.
D.

51 . A developer creates a new Apex trigger with a helper class, and writes a test class that only
exercises 95% coverage of new Apex helper class
Change Set deployment to production fails with the test coverage warning:
"Test coverage of selected Apex Trigger is 0%, at least 1% test coverage is required"
What should the developer do to successfully deploy the new Apex trigger and helper class?
A. Increase the test class coverage on the helper class
B. Remove the falling test methods from the test class.
C. Run the tests using the 'Run All Tests' method.
D . Create a test class and methods to cover the Apex trigger

52 . A developer creates a custom exception as shown below:


What are two ways the developer can fire the exception in Apex? (Choose 2 answers)
A. Throw new ParityException (parity does not match);
B. New ParityException( );
C. Throw new parityException ( );
D. New ParityException (parity does not match);

53 . 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?
A. Disable the batch job and recreate it with a smaller number of records.
B. Decreas the batch size to reduce the load on the system.
C Check the debug logs for the batch job.
D. Check the asynchronous job monitoring page to view the joh status and logs.
54. When using Salesforce DX, what does a developer need to enable to create and manage scratch
orgs?
A. Production
D. Dev Hub
C. Environment Hub
D. Sandbox

55 . A developer creates a Lightning web component that imports a method within an Apex class.
When a Validate button is pressed, the method runs to execute complex validations.
In this implementation scenario, which two options are part of the Controller according to the MVC
architecture? (Choose 2 answers)
A. JavaScript file
B. Apex Class
C. HTML
D. XML file

56 . A developer created these three Rollup Summary fields in the custom object, Project_c:
Total Timesheets_c
Total Approved_Timesheet_c
Total Rejected_Timesheet_c
The developer is asked to create a new field that shows the ratio between rejected and approved
timesheets for a given project.
Which should the developer use to implement the business requirement in order to minimize
maintenance overhead?
A. Apex trigger
B. Formula field
C. Record-triggered flow
D. Roll up summary field

57 . A developer wants to send an outbound message when a record meets a specific criteria.
Which two features satisfy this use case? (Choose 2 answers)
A. Next Best Action can be used to check the record criteria and send an outbound message
B. Flow Builder can be used to check the record criteria and send an outbound message.
C. Approval Process can be used to check the record criteria and send an outbound message without
Apex code.
D. Entitlement Process can be used to check the record criteria and send en outbound messa without
Apex code.

58 . Which statement is true regarding execution order when triggers are associated to the same
object and event?
A. Trigger execution order cannot be guaranteed.
B. Triggers are executed alphabetically by trigger name.
C. executed In the order they are modified.
D. Triggers are executed in the order they are created.

59 . Universal Hiring is using Salesforce to capture job applications. A salesforce administrator


created two custom objects; Job_c acting as the master object, Job_Application_c acting as the
detail.
Within the Job_c object, a custom multi-select picklist, Preferred_Locationsc, contains a list of
approved states for the position. Each Job_Application_c record relates to a Contact within the
system through a master-detail relationship.

Recruiters have requested the ability to view whether the Contact's Mailing State value matches a
value selected on the Preferred_Locations_c field, within the Job_Applicationc record. Recruiters
would like this value to be kept in sync, if changes occur to the Contact's Mailing State or if the Job's
Preferred_Locations_c field is updated.

What is the recommended tool a developer should use to meet the business requirement?
A. Apex Digger
B. Process Builder
C. Record-triggered flow
D. Formula field

60 . 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 two.)
A. SFDX CLI
B. Developer Console
C. Change Sets
D. Ant Migration Tool
61 . What should a developer use to script the deployment and unit test execution as part of
continuous integration?
4. Developer Console
B. Salesforce CLI
C. Execute Anonymous
D. VS Code

62 . The Job_Application_c custom object has a field that is a Master-Detail relationship to the
Contact object, where the Contact object is the Master. As part of a feature implementation, a
developer needs to retrieve a list containing all Contact records where the related Account Industry
is `Technology' while also retrieving the contact's Job_Application_c records.
Based on the object's relationships, what is the most efficient statement to retrieve the list of
contacts?
A. [SELECT Id, (SELECT Id FROM Job_Applications_r) FROM Contact WHERE Account.Industry =
'Technology'];
B. [SELECT Id, (SELECT Id FROM Job_Applications_r) FROM Contact WHERE Accounts.Industry =
'Technology'];
C. [SELECT Id, (SELECT Id FROM Job_Applications_c) FROM Contact WHERE Accounts.Industry =
'Technology'];
D. [SELECT Id, (SELECT Id FROM Job_Application_c) FROM Contact WHERE Account.Industry =
'Technology'];

63 . Universal Containers hires a developer to build a custom search page to help user- find the
Accounts they want. Users will be able to search on Name, Description, and a custom comments
field.
Which consideration should the developer be aware of when deciding between SOQ1 Mid SOSI ?
( Choose 2 answers )
A. SOQL is able to return more records.
B. SOQL is faster for text searches.
C. SOSL is able to return more records.
D. SOSL is faster for tent searches

64 . A developer needs to allow users to complete a form on an Account record that will create a
record for a custom object.
The form needs to display different fields depending on the user’s job role. The functionality should
only be available to a small group of users.
Which three things should the developer do to satisfy these requirements? ( Choose 3 answers )
A . Add a dynamic action to the Account record page.
B . Create a custom permission for the users.
C . Create a Lightning web component.
D . Add a dynamic action to the user’s assigned page layouts.
E . Create a dynamic form.

65 . A developer is migrating a Visualforce page into a Lightning web component.


The Visualforce page shows information about a single record. The developer decides to use
Lightning Data Service to access record data.
Which security consideration should the developer be aware of?

A. Lightning Data Service handles sharing rules and field-level security.


B. The with sharing keyword must be used to enforce sharing rules.
C. The isAccessible ( ) method must be used for field-level access checks
D. Lightning Data Service ignores field-level security.

------------ END -----------


SET2

1. 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?

A. Use a MAX Roll-Up Summary field on the latest availability date fields.
B. Use a LATEST 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. D. Use a CEILING formula on each of the latest availability date fields,

2. Universal Containers wants to ensure that all new leads created in the system have a valid
email address. They have already created a validation rule to enforce this requirement, but
want to add an additional layer of validation using Apex code. What would be the best
solution for this requirement?

A. Use a Process Builder to validate the email address and display. Message if it is
invalid error

B. Use a trigger on the Lead object to validate the email address and display an error
message if it is invalid.

C. Create a time-based workflow rule that updates the email address if it is Invalid

D. Submit a REST API Callout with a JSON payload and validate the fields on a third
party system.

3. Refer to the following Apex code: Integer X 02 do { x= 1; x++;


} while (x < 1);
System.debug(x);

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

A. 0 B. 1 C. 2
D. 3

4. What is the benefit of developing applications in a multi-tenant environment?

A. Pre configured storage for big data


B. Enforced unit testing and code coverage best practices
C. Access to predefined computing resources
D. Unlimited processing power and memory

5. 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?

A. Scratch orgs
B. Developer Sandboxes
C. Developer orgs
D. Full Copy Sandboxes
6. Universal Containers uses Service Cloud with a custom field, Stage__c, on the Case object.
Management wants to send a follow-up email reminder to the Case Owner 6 hours after the
stage_c field is set to “Waiting on Customer”. The Salesforce Administrator wants to ensure
the solution used is bulk safe.
Which automation tool should a developer recommend to meet these business
requirements?
A. Entitlement Process
B. Record Triggered flow with a scheduled path
C. Scheduled flow
D. Einstein Next Best Action
7. 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?
A. Use the Apex Interactive Debugger to step through the code and Identify the Issue.

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

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

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

8. Universal Containers needs to create a custom user interface component that allows users to
enter information about their accounts. The component should be able to validate the user
input before saving the information to the database.

What is the best technology to create this component?

A. Flow
B. VUE Javascript framework
C. Visualforce
D. Lightning Web Components
9. A developer must troubleshoot to pinpoint the causes of performance issues when a custom
page loads in their org.
Which tool should the developer use to troubleshoot query performance?
A. Visual Studio Code IDE
B. Setup Menu
C. AppExchange
D. Developer Console
10. How can a developer check the test coverage of active Process Builder and Flows deploying
them in a Changing Set?
A. Use the Flow properties page.

B. Use the code Coverage Setup page

C. Use SOQL and the Tooling API

D. Use the Apex testresult class

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

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

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

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

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

12. 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?

A. Use a try/catch with a custom exception class.

B. Include <apex: messages> on the Visualforce page.

C. Perform the DML using the Database.upsert() method.

D. Add custom controller attributes to display the message.

13. A developer must provide custom user interfaces when users edit a Contact in either
Salesforce Classic or Lightning Experience.
What should the developer use to override the Contact’s Edit button and provide this
functionality?

A. A Visualforce page in Salesforce Classic and a Lightning component in Lightning


Experience
B. A Visualforce page in Salesforce Classic and a Lightning page in Lightning
Experience
C. A Lightning page in Salesforce Classic and a Visualforce page in Lightning
Experience.
D. A Lightning component in Salesforce Classic and a Lightning component in Lightning
Experience .

14. A developer has an integer variable called maxAttempts. The developer needs to ensure that
once maxAttempts is initialized, it preserves its value for the length of the Apex transaction;
while being able to share the variable’s state between trigger executions.
How should the developer declare maxAttempts to meet these requirements?

A. Declare maxAttempts as a private static variable on a helper class.


B. Declare maxAttempts as a variable on a helper class.
C. Declare maxAttempts as a member variable on the trigger definition.
D. Declare maxAttempts as a constant using the static and final keywords

15. A developer must create a Lightning component that allows users to input Contact record
information to create a Contact record, including a Salary__c custom field. What should the
developer use, along with a lightning-record-edit-form, so that Salary__c field functions as a
currency input and is only viewable and editable by users that have the correct field level
permissions on Salary__c?

A. <lightning-input-field field-name=’Salary__c’>
</lightning-input-field>
B. <lightning-formatted-number value=’Salary__c’ format-style=’currency’>
</lightning-formatted-number>
C. <lightning-input type=’number’ value=’Salary__c’ formatter=’currency’>
</lightning-input>
D. <lightning-input-currency value=’Salary__c’>
</lightning-input-currency>

16. What will be the output in the debug log in the event of a QueryException during a call to
the aQuery method in the following example?

public class myClass {


Class CustomException extends Exception {}
Public static Account aQuery() {
Account theAccount;
Try {
System.debug(‘Querying Accounts.’);
theAccount = [SELECT Id FROM Account WHERE CreatedDate > TODAY];
} catch(CustomException eX) {
System.debug(‘Custom Exception.’);
} catch(QueryException eX) {
System.debug(‘Query Exception.’);
} Finally {
System.debug(‘Done.’);
}
return theAccount;
}
}

A. Querying Accounts.
Query Exception.

B. Querying Accounts.
Custom Exception.

C. Querying Accounts.
Custom Exception.
Done.

D. Querying Accounts. Query Exception.


Done.

17. Which Lightning code segment should be written to declare dependencies on a Lightning
component, c: accountList, that is used in a Visualforce page?

A. <aura:component access-“GLOBAL” extends-“itngoutApp”>


<aura:dependency resource = “c:accountList”/>

</aura:component>

B. <aura: application access-“GLOBAL”>


<aura:dependency resource =”c:accountList”/>

</aura: application>
C. <aura:application access-GLOBAL” extends-“itng:outApp”>
<aura: dependency resource=”c:accountList”>
</aura: application>

D. <aura:component access-“GLOBAL”>
<aura: dependency resource=”c:accountList”/>

</aura:component>

18. A developer wants to mark each Account in a List<Account> as either or Inactive based on
the LastModifiedDate field value being more than 90 days. Which Apex technique should the
developer use?

A. A for loop, with a switch statement inside

B. An If/else statement, with a for loop inside

C. A Switch statement, with a for loop inside

D. A for loop, with an if/else statement inside

19. A developer is creating an app that contains multiple Lightning web components. One of the
child components is used for navigation purposes. When a user click a button called..
component, the parent component must be alerted so it can navigate to the next page.
How should this be accomplished?

A. Create a custom event

B. Update a property on the parent.

C. Call a method in the Apex controller.

D. Fire a notification.

20. 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?
A. 2 B. 1 C. 3
D. 4

21. A developer must create a CreditCardPayment class that provides an implementation of an


existing Payment class.

public virtual class Payment { public virtual void makePayment


(Decimal amount) {
/*Implementation*/ }

Which is the correct implementation?

A. public class CreditcardPayment implements Payment { public


virtual void makePayment (Decimal amount) {
/*Implementation*/ }
}

B. public class CreditcardPayment extends Payment { public


virtual void makePayment (Decimal amount) {
/*Implementation*/ }
}

C. public class CreditcardPayment implements Payment { public


override void makePayment (Decimal amount) {
/*Implementation*/ }
}
D. public class CreditcardPayment extends Payment { public
override void makePayment (Decimal amount) {
/*Implementation*/ }
}
22. The following code snippet is executed by a Lightning web component in an environment
with more than 2,000 lead records:

@AuraEnabled
Public static void updateLeads() {
For (Lead thisLead : [SELECT Origin FROM Lead]) {
thisLead.LeadSource = ‘Some Source’; // Example field update update
thisLead;
thisLead.Origin__c = ‘Some Origin’; // Example custom field update
}
}

Which governor limit will likely be exceeded within the Apex transaction?

A. Total number of records processed as a result of DML statements

B. Total number of SOQL queries issued

C. Total number of DML statements issued

D. Total number of records retrieved by SOQL queries

23. 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. global class WebServiceClass { private static

Boolean helperMethod() {

/* implementation*/

global string updateRecords() {


// implementation

B. webservice class WebServiceClass { private static


Boolean helperMethod(){
/*implementation*/
}
global static string updateRecords(){
/*implementation*/
}

C. webservice class WebServiceClass { private static


Boolean helperMethod(){
/*implementation*/
}
webservice static string updateRecords(){
/*implementation*/
}

D. global class WebServiceClass { private static


Boolean helperMethod(){
/*implementation*/
}
gobal static string updateRecords(){
/*implementation*/
}

24. A developer created these three Rollup Summary fields in the custom object, Project__c:

Total Timesheets __c


Total Approved Timesheets__c
Total Rejected Timesheet__c

The developer is asked to create a new field that shows the ratio between rejected and
approved timesheets for a given project.
Which should the developer use to implement the business requirement in order to
minimize maintenance overhead?

A. Apex trigger
B. Record-triggered flow
C. Roll-up summary Field
D. Formula Field

25. Given the following Anonymous block : List<Case> casesToUpdate = new List<Case>(); for
(Case thisCase: [Select Id, Status FROM Case LIMIT 50000]) { thisCase. Status = ‘Working’;
casesToUpdate.add(thisCase);
}
try{
Database.update (casesToUpdate, false); }
catch (Exception e) {
System.debug(e.getMessage());
}
What should a developer consider for an environment that has over 10,000 Case records?

A. The transaction will succeed and changes will be committed.


B. The transaction will fail due to exceeding the governor limit.
C. The try/catch block will handle any DML exceptions thrown.
D. The try/catch block will handle exceptions thrown by governor limits.

26. 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?

A. Use the schema describe calls to determine if the logged-in user has access to the
Account object.
B. Use the UserInfo Apex class to filter all SOQL queries to returned records owned by
the logged-in user.
C. Use the with sharing keyword on the class declaration.
D. Use the without sharing keyword on the class declaration.

27. Consider the following code snippet :

public static List<Lead> obtainAllFields(Set<Id> leadIds) {


List<Lead> result = new List<Lead>();
for (Id leadId : leadIds) {
result.add([SELECT FIELDS (STANDARD) FROM Lead WHERE Id = :leadId]);
}

return result;

}
Given the multi-tenant architecture of the Salesforce platform, what is a best practice a
developer should implement and ensure successful execution of the method?

A. Avoid returning an empty List of records.


B. Avoid executing queries without a limit clause.
C. Avoid performing queries Inside for loops.
D. Avoid using variables as query filters.

28. How does the Lightning Component framework help developers implement solutions faster?
A. By providing an Agile process with default steps
B. By providing code review standards and processes
C. By providing device-awareness for mobile and desktops
D. By providing change history and version control

29. A developer created a custom order management app that uses an Apex class. The order is
represented by an Order object and an Orderltem object that has a masterdetail relationship
to Order. During order processing, an order may be split into multiple orders.
What should a developer do to allow their code to move some existing Orderltem records to
a new Order record?

A. Change the master-detail relationship to an external lookup relationship.


B. Create a junction object between Orderltem and Order.
C. Add without sharing to the Apex class declaration.
D. Select the Allow reparenting option on the master-detail relationship.

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

A. @InvocableMethod(label=”Additional Info”) public


List<contactInfo> getInfo(List<Id> contactIds) {

/*implementation*/
}

B. @InvocableMethod(label=”Additional Info”) public


static contactInfo getInfo(Id contactId) {

/*implementation*/
}

C. @InvocableMethod(label=”Additional Info”) public


contactInfo getInfo(Id contactId) {

/*implementation*/
}

D. @InvocableMethod(label=”Additional Info”) public


static List<ContactInfo> getInfo(List<Id> contactIds) {

/*implementation*/
}

31. A PrimaryId__c custom field exists on the candidate C custom object. The field is used to
store each candidate’s id number and is marked as Unique in the schema definition.
As part of a data enrichment process, Universal Containers has a CSV file that contains
updated data for all candidates in the system. The file contains each Candidate’s primary id
as a data point. Universal Containers wants to upload this information into Salesforce, while
ensuring all data rows are correctly mapped to a candidate in the system.
Which technique should the developer implement to streamline the data upload?

A. Create a before Insert trigger to correctly map the records.


B. Upload the CSV Into custom object related to Candidate.
C. Create a before save flow to correctly map the records.
D. Update the PrimaryId__c field definition to mark it as an External
Id.

32. Developer created this Apex trigger that calls MyClass.myStaticMethod:


trigger myTrigger on Contact(before insert)

MyClass.myStaticMethod(trigger.new);

The developer creates a test class with a test method that calls MyClass.myStaticMethod,
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?
A. The deployment fails because no assertions were made in the test
method.
B. The deployment passes because both classes and the trigger were
included in the deployment.
C. The deployment passes because the Apex code has required (>75%)
code coverage.
D. The deployment fails because the Apex trigger has no code
coverage.

33. Universal Containers is developing a new Lightning web component for their marketing
department. They want to ensure that the component is fine tuned and provides a seamless
user experience.
What are some benefits of using the Lightning Component framework?
A. Automatic support for accessibility standards
B. Compatibility with all web browsers
C. Better performance due to client-side rendering
D. Easy Integration with third-party libraries

34. Universal Containers has developed custom Apex code and Lightning Components in a
Sandbox environment. They need to deploy the code and associated configurations to the
Production environment.
What is the recommended process for deploying the code and configurations to Production?

A. Use the Ant Migration Tool to deploy the Apex code and Lightning Components.
B. Use Salesforce CLI to deploy the Apex code and Lightning Components.
C. Use a change set to deploy the Apex code and Lightning Components.
D. Use the Force.com IDE to deploy the Apex code and Lightning Components.

35. A developer is creating a Lightning web component to show a list of sales records. The Sales
Representative user should be able to see the commission field on each record. The Sales
Assistant user should be able to see all fields on the record except the commission field.
How should this be enforced so that the component works for both users without showing
any errors?
A. Use Lightning Data Service to get the collection of sales records.
B. Use WITH SECURITY_ENFORCED in the SOQL that fetches the data for the
component.

C. Use Lightning Locker Service to enforce sharing rules and field-level security.

D. Use Security.stripInaccessible to remove fields inaccessible to the current user.

36. 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?
A. Use the Streaming API to create real-time roll-up summaries.
B. Write a trigger on the Opportunity object and use an aggregate function to sum
the amount for all related child objects under the Opportunity.
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.

37. The OrderHelper class is a utility class that contains business logic for processing orders.
Consider the following code snippet:
public class without sharing OrderHelper
{
//code implementation
}
A developer needs to create a constant named DELIVERY MULTIPLIER with a value of 4.15.
The value of the constant should not change at any time in the code. How should the
developer declare the DELIVERY MULTIPLIER constant to meet the business objectives?
A. constant decimal DELIVERY_MULTIFILTER = 4.15;

B. static final decimal DELIVERY_MULTIFILTER = 4.15;

C. static decimal DELIVERY_MULTIFILTER = 4.15;

D . decimal DELIVERY_MULTIFILTER = 4.15;

38. What can be easily developed using the Lightning Component framework?
A. Customized JavaScript buttons
B. Salesforce Classic user Interface pages
C. Salesforce integrations
D. Lightning Pages

39. In the Lightning UI, where should a developer look to find information about a Paused Flow
Interview?
A. On the Paused Flow Interviews related list for a given record
B. In the system debug log by filtering on Paused Flow Interview
C. In the Paused Interviews section of the Apex Flex Queue
D. On the Paused and failed Flow Interviews page under Setup > Process
Automation

40. 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 Fields RETURNING lead(id, name),


account(id, name), contact (id, name)

B. SELECT lead(id, name), account(id, name), contact( id, name) FROM


Lead, Account, Contact WHERE Name = “Universal Containers”

C. SELECT Lead.id. Lead.Name, Account. Id, Account Name, Contact.id,


Contact Name FROM Lead, Account, Contact WHERE CompanyName = “Universal
Containers”

D. FIND ‘Universal Containers” IN Name Fields RETURNING Lead(id, name),


account(id, name), contact (id, name)

41. . A developer has the following requirements:


• Calculate the total amount on an Order.
• Calculate the line amount for each Line Item based on quantity selected and price.
• Move Line Items to a different Order if a Line Item is not in stock.
Which relationship implementation supports these requirements on its own?

A. Line Item has a re-parentable lookup field to Order.


B. Order has re-parentable master-detail field to Line Item.
C. Order has a re-parentable lookup field to Line Item.
D. Line Item has a re-parentable master-detail field to Order.

42. Universal Containers wants Opportunities to be locked from editing when reaching the
Closed/Won stage. Which two strategies should a developer use to accomplish this? (Choose
two.)

A. Use a Flow Builder.


B. Use a validation rule.
C. Use the Process Automation Settings.
D. Mark fields as read-only on the page layout.

43. What does the Lightning Component framework provide to developers?


A. Extended governor limits for applications
B. Templates to create custom components
C. Prebuilt components that can be reused
D. Support for Classic and Lightning UIs

44. A Salesforce Administrator used Flow Builder to create a flow named “accountOnboarding”.
The flow must be used inside an Aura component.
Which tag should a developer use to display the flow in the component?
A. lightning-flow
B. aura-flow
C. lightning:flow
D. aura:flow
45. A large corporation stores Orders and Line Items in Salesforce for different lines of business.
Users are allowed to see Orders across the entire organization, but, for security purposes,
should only be able to see the Line Items for Orders in their line of business.
Which type of relationship should be used between Line Items and Orders?

A. Lookup
B. Direct Lookup
C. Master-Detail
D. Indirect Lookup
46. A developer needs to have records with specific field values in order to test a new Apex class.
What should the developer do to ensure the data is available to the test? A. Use
SOQL to query the org for the required data.
B. Use Teat loadData() and reference a JSON file in Documents.
C. Use Anonymous Apex to create the required data.
D. Use Text.loadData() and reference a CSV file in a static resource.

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

A. Execute Anonymous
B. Developer Console
C. VS Code
D. Salesforce CLI

48. Given the following Apex statement:


Account myAccount [SELECT Id, Name FROM Account);
What occurs when more than one Account is returned by the SOQL query? A. The
query fails and an error is written to the debug log.
B. An unhandled exception is thrown and the code terminates.
C. The first Account returned is assigned to myAccount.
D. The variable, myAccount, is automatically cast to the List data type.
49. A developer is writing tests for a class and needs to insert records to validate functionality.
Which annotation method should be used to create records for every method in the test
class?
A. @PreTest
B. @StartTest
C. @isTest(SeeAllData=true)
D. @TestSetup

50. What should a developer use to fix a Lightning web component bug in a sandbox?
A. Force.com IDE
B. Execute Anonymous
C. Developer Console
D. VS Code

51. A developer migrated functionality from JavaScript demoting to a Lightning web component
and wants to use the existing getOpportunities() method to provide data.
Which modification to the method is necessary?
A. The method must be decorated with @AuraEnabled.
B. The method must return a JSON Object.
C. The method must be decorated with (cacheable=true).
D. The method must return a String of a serialized JSON Array.

52. Which scenario is valid for execution by unit tests?


A. Load data from a remote site with a callout.
B. Generate a Visualforce PDF with getcontentAsPDF().
C. Set the created date of a record using a system method.
D. Execute anonymous Apex as a different user.

53. A custom picklist field, Food Preference c, exists 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 optimal way to ensure a
value is selected every time a record is saved?

A. Mark the field as Required on the object’s page layout.


B. Mark the field as Required on the field definition. C. Write an Apex
trigger to ensure value is selected.
D. Set “Use the first value in the list as the default value” to True.

54. A developer wrote Apex code that calls out to an external system using REST API.
How should a developer write the test to prove the code is working as intended? A. Write
a class that extends HTTPCalloutMock.
B. Write a class that extends WebServiceMock.
C. Write a class that implements WebServiceMock.
D. Write a class that implements HTTPCalloutMock.

55. A custom object Trainer has a lookup field to another custom object Gym .
Which SOQL query will get the record for the Viridian City Gym and all it’s trainers?

A. SELECT ID FROM Trainer__c WHERE Gym__r.Name =’Viridian City Gym’

B. SELECT Id, (SELECT Id FROM Trainer__c ) FROM Gym__c WHERE Name =’Viridian City
Gym’

C. SELECT Id, (SELECT Id FROM Trainers__r ) FROM Gym__c WHERE Name =’Viridian
City Gym’

D. SELECT Id, (SELECT Id FROM Trainer__c ) FROM Gym__c WHERE Name =’Viridian City
Gym’
56. A developer wants to import 500 Opportunity records into a sandbox. Why should the
developer choose to use Data Loader instead of Data Import Wizard?
A. Data Loader runs from the developer’s browser.
B. Data Loader automatically relates Opportunities to Accounts.
C. Data Import Wizard does not support Opportunities.
D. Data Import Wizard can not import all 500 records.

57. 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?

A. Use the Data Import Wizard to Import the data and set up field-level security to
restrict access to sensitive fields.
B. Use a third-party tool to encrypt the sensitive data before Importing it into
Salesforce.
C. Use the Salesforce CLI to import the data and set up user permissions to restrict
access to sensitive data.
D. Use the Apex Data Loader to import the data and write Apex code to handie security
and access control.

58. A developer has a requirement to write Apex code to update a large number of account
records on a nightly basis. The system administrator needs to be able to schedule the class to
run after business hours on an as-needed basis.
Which class definition should be used to successfully implement this requirement?

A. public inherited sharing class ProcessAccountProcessor implements Schedulable


B. public inherited sharing class ProcessAccountProcessor implements
Database.Batchable<sobject>, Schedulable
C. public inherited sharing class ProcessAccountProcessor implements Queueable
D. public inherited sharing class ProcessAccountProcessor implements
Database.Batchable<sobject>

59. 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?

A. Add a new Get Records element.


B. Add a new Roll Back Records element.
C. Add a new Update Records element.
D. Add a new Create Records element.
60. Cloud Kicks has a multi-screen flow that its call center agents use when handling inbound
service desk calls.
At one of the steps in the flow, the agents should be presented with a list of order numbers
and dates that are retrieved from an external order management system in real time and
displayed on the screen.
What should a developer use to satisfy this requirement?
A. An Apex controller
B. An invocable method
C. An outbound message
D. An Apex REST class

61. A developer is designing a new application on the Salesforce platform and wants to ensure it
can support multiple tenants effectively.
Which design framework should the developer consider to ensure scalability and
maintainability?

A. Agile Development
B. Waterfall Model
C. Model-View-Controller (MVC)
D. Flux (view, action, dispatcher, and store)

62. Which action may cause triggers to fire? A. Renaming or replacing a picklist entry
B. Updates to Feed Items
C. Changing a user’s default division when the transfer division option is checked
D. Cascading delete operations

63. 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?

A. Share the parent Case and Defect__c records.


B. Share the parent Case record.
C. Share the Case_Defect__c record.
D. Share the parent Defect__c record.

64. Since Aura application events follow the traditional publish- subscribe model, which method
is used to fire an event?
A. fireEvent()
B. registerEvent()
C. emit()
D. fire()

65. The Job_Application__c custom object has a field that is a master-detail relationship to the
Contact object, where the Contact object is the master.
As part of a feature implementation, a developer needs to retrieve a list containing all
Contact records where the related Account Industry is ‘Technology’, while also retrieving the
Contact’s Job_Application__c records.
Based on the object’s relationships, what is the most efficient statement to retrieve the list
of Contacts?

A. [SELECT Id, (SELECT Id FROM Job_Applications_r) FROM Contact WHERE


Account.Industry = ‘Technology’];

B. [SELECT Id, (SELECT Id FROM Job_Applications_c) FROM Contact WHERE


Accounts.Industry = ‘Technology’];

C. [SELECT Id, (SELECT Id FROM Job_Applications_r) FROM Contact WHERE


Accounts.Industry = ‘Technology’];

D. [SELECT Id, (SELECT Id FROM Job_Application_c) FROM Contact WHERE


Account.Industry = ‘Technology’];

-----------END------------
SET 4
1 . 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?
A. Callout from a Queueable class called from a trigger
B. Callout from a Batchable class called from a scheduled job
C. Flow with a callout from an invocable method
D. Callout from an @future method called from a trigger

2. When a user edits the Postal Code on an Account, a custom Account text field
named "Timezone" must be updated based on the values in a
PostalCodeToTimezone__c custom object.
Which two automation tools can be used to implement this feature?
A Quick actions
B. Approval process
C Account trigger
D. Fast Field Updates record-triggered flow

3. As part of new feature development, a developer is asked to build a responsive


application capable of responding to touch events, that will be executed on stateful
clients.
Which two technologies are built on a framework that fully supports the business
requirement?
A. Lightning Web Components
B. Visualforce Components
C. Visualforce Pages
D. Aura Component
4. A developer has the following requirements:
• Calculate the total amount on an Order.
• Calculate the line amount for each Line Item based on quantity selected and price.
• Move Line Items to a different Order if a Line Item is not in stock.
Which relationship implementation supports these requirements on its own? A.
Line Item has a re-parentable master-detail field to Order.
B. Line Item has a re-parentable lookup field to Order.
C. Order has a re-parentable lookup field to Line Item.
D. Order has a re-parentable master-detail field to Line Item.

5. 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. global class WebServiceClass ( private static Boolean helperMathod() {/*


implementation…*/} global String updateRecords() { /*implementation…*/}
}

B. webservice class WebserviceClass (


private static Boolean helperMethod() {/* implementation…*/}

global static String updateRecords() {/* implementation…*/}


}
C. webservice class WebserviceClass (
private static Boolean helperMethod() {/* implementation…*/}
Webservice static string updateRecords() {/* implementation…*/}
}
D. global class WebserviceClass(
private static Boolean helperMethod() {/* implementation…*/}
}

6. 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?
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.

7. A developer needs to make a custom Lightning Web Component available in the


Salesforce Classic user interface.
Which approach can be used to accomplish this?
A. Embed the Lightning Web Component is a Visualforce Component and add
directly to the page layout.
B. Use the Lightning Out JavaScript library to embed the Lightning Web
Component in a Visualforce page and add to the page layout.
C. Use a Visualforce page with a custom controller to invoke the Lightning Web
Component using a call to an Apex method.
D. Wrap the Lightning Web Component in an Aura Component and surface the
Aura Component as a Visualforce tab.

8. What can be used to override the Account's standard Edit button for Lightning
Experience?
A. Lightning action
B. Lightning page
C. Lightning component
D. Lightning flow
9. A developer created this Apex trigger that calls MyClass.myStaticMethod:
trigger myTrigger on Contact (before insert)
{ MyClass.myStaticMethod(trigger.new); }
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?
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 falls because the Apex trigger has no code coverage.

10. A developer needs to create a baseline set of data (Accounts, Contacts, Products,
Assets) for an entire suite of Apex tests allowing them to test isolated requirements
for various types of Salesforce cases.
Which approach can efficiently generate the required data for each unit test? A.
Create a mock using the HttpCalloutMock interface.
B. Use @TestSetup with a void method.
C. Add @IsTest(seeAllData=true) at the start of the unit test class.
D. Create test data before Test.startTest() in the unit test.

11. A developer must troubleshoot to pinpoint the causes of performance issues


when a custom page loads in their org.
Which tool should the developer use to troubleshoot query performance?
A. Setup Menu
B. Visual Studio Code IDE
C. AppExchange
D. Developer Console
12. A company has a custom object, Order_c, that has a required, unique external ID
field called Order_Number_c.
Which statement should be used to perform the DML necessary to insert new records
and update existing records in a list of Order__c records using the external ID field?
A. merge orders;
B. merge orders Order_Number__c;
C. upsert orders Order_Number__c;
D. upsert orders;

13. 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? 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.

14. 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
for various types of Salesforce Cases.
Which approach can efficiently generate the required data for each unit test? A.
Create a mock using the Stub API.
B. Create test data before Test.startTest() in the unit test.
C. Use @TestSetup with a void method.
D. Add @IsTest(seeAllData=true) at the start of the unit test class

15. Which Lightning Web Component custom event property settings enable the
event to bubble up the containment hierarchy and cross the Shadow DOM boundary?
A. bubbles: true, composed: false
B. bubbles: false, composed: false
C. bubbles: true, composed: true
D. bubbles: false, composed: true

16. Universal Containers needs to create a custom user interface component that
allows users to enter information about their accounts. The component should be
able to validate the user input before saving the information to the database.
What is the best technology to create this component?
A. Flow
B. Lightning Web Components
C. Visualforce
D. VUE JavaScript framework

17. How should a developer write unit tests for a private method in an Apex class? A.
Use the SeeAllData annotation.
B. Add a test method in the Apex class.
C. Mark the Apex class as global.
D. Use the @TestVisible annotation.

18. Assuming that name is a String obtained by an <apex: inputText> tag


on a Visualforce page, which two SOQL queries performed are safe from SOQL
injection?

A. String query = ‘%’ + name + ‘%’;


List <Account> results [SELECT Id FROM Account WHERE Name LIKE :query];

B. String query = ‘SELECT Id FROM Account WHERE Name LIKE \’%’ +


name.noQuotes() + ‘%\’’;)
List <Account> results = Database.query(query);

C. String query = ‘SELECT Id FROM Account WHERE Name LIKE \’%’ +


String.escapeSingleQuotes(name) + ‘%\’’;
List <Account> results = Database.query(query);

D. String query = ‘SELECT Id FROM Account WHERE Name LIKE \‘%’ +


name +
‘%\’’;
List <Account> results = Database.query(query);

19. Universal Containers has implemented an order management


application. Each
Order can have one or more Order Line items. The Order Line object is related to the
Order via a master-detail relationship. For each Order Line item, the total price is
calculated by multiplying the Order Line item price with the quantity ordered.
What is the best practice to get the sum of all Order Line item totals on the Order
record?
A. Roll-up summary field
B. Formula field
C. Apex trigger
D. Quick action

20. Refer to the following Apex code:


Integer x = 0; do{
x = 1;
x ++;
} while (x < 1) ;
System.debug(x);
What is the value of x when it is written to the debug log?
A. 0
B. 1

C. 2
D. 3
21. While developing an Apex class with custom search functionality that will be
launched from a Lightning Web Component, how can the developer ensure only
records accessible to the currently logged in user are displayed? A. Use the
WITH SECURITY_ENFORCED clause within the SOQL.
B. Use the inherited sharing keyword.
C. Use the with sharing keyword.
D. Use the without sharing keyword.

23. 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

24. While working in a sandbox, an Apex test fails when run in the Test Runner.
However, executing the Apex logic in the Execute Anonymous window succeeds with
no exceptions or errors.
Why did the method fail in the sandbox test framework but succeed in the Developer
Console?
A. The test method does not use System.runAs to execute as a specific user.
B. The test method is calling an @future method.
C. The test method relies on existing data in the sandbox.
D. The test method has a syntax error in the code.

25. How many Accounts will be inserted by the following block of code?
for (Integer i=0; i < 500; i++) (
Account a = new Account (Name='New Account ‘+ i);
insert a;
}
A. 100
B. 0
C. 150
D. 500

26. Which two characteristics are true for Lightning Web Component custom events?
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
detall.
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.

27. Cloud Kicks has a multi-screen flow that its call center agents use when handling
inbound service desk calls.
At one of the steps in the flow, the agents should be presented with a list of order
numbers and dates that are retrieved from an external order management system in
real time and displayed on the screen.
What should a developer use to satisfy this requirement?
A. An outbound message
B. An Apex REST class
C. An Apex controller
D. An invocable method

28. Where are two locations a developer can look to find information about the
status of batch or future methods?
A. Developer Console
B. Apex Jobs
C. Paused Flow Interviews component
D. Apex Flex Queue
29. A lead developer creates a virtual class called "OrderRequest". Consider the
following code snippet:
public class CustomerOrder(
//code implementation
}
How can a developer use the OrderRequest class within the CustomerOrder class?
A. @Extends (class="OrderRequest") public class CustomerOrder
B. public class CustomerOrder implements Order
C. public class Customerorder extends OrderRequest D.
@Implements (class="OrderRequest") public class
CustomerOrder

30. What is the value of the Trigger.old context variable in a before insert trigger?
A. An empty list of sObjects
B. Undefined
C. null
D. A list of newly created sObjects without IDs

31. public static void insertAccounts (List<Account> theseAccounts) {


for (Account thisAccount : theseAccounts) ( if
(thisAccount.website == null) { thisAccount.website =
'https://www.demo.com';
}
}
update theseAccounts;
}
When the code executes, a DML exception is thrown.
How should a developer modify the code to ensure exceptions are handled
gracefully?
A. Implement the upsert DML statement.
B. Implement Change Data Capture.
C. Implement a try/catch block for the DML.
D. Remove null items from the list of Accounts.

33. A developer wants to import 500 Opportunity records into a sandbox.


Why should the developer choose to use Data Loader instead of Data Import Wizard?
A. Data Loader automatically relates Opportunities to Accounts.
B. Data Loader runs from the developer's browser.
C. Data Import Wizard does not support Opportunities.
D. Data Import Wizard can not Import all 500 records.

34. 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. @InvocableMethod global List<List<Recommendation>> getLevel
(List<ContactWrapper> input)
{/*implementation"/}
B. @InvocableMethod global Recommendation getlevel
(ContactWrapper input)
{/*implementation"/}
C. @InvocableMethod
global static ListRecommendation getLevel (List<ContactWrapper input)
{/*implementation"/}
D. @InvocableMethod global static List<List<Recommendation>>
getLevel ( List <ContactWrapper> input)
35. Universal Containers decided to transition from Classic to Lightning Experience.
They asked a developer to replace a JavaScript button that was being used to create
records with prepopulated values.
What can the developer use to accomplish this?
A. Validation rules
B. Apex triggers
C. Record triggered flows
D. Quick Actions

36. Universal Containers has developed custom Apex code and Lightning Components
in a Sandbox environment. They need to deploy the code and associated
configurations to the Production environment.
What is the recommended process for deploying the code and configurations to
Production?
A. Use the Force.com IDE to deploy the Apex code and Lightning Components.
B. Use the Ant Migration Tool to deploy the Apex code and Lightning
Components.
C. Use a change set to deploy the Apex code and Lightning Components.
D. Use Salesforce CLI to deploy the Apex code and Lightning Components.

37. In the following example, which sharing context will myMethod execute when it
is invoked?
public Class myClass {
public void myMethod() { /* implementation */ }
}
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.
38. What are two considerations for deploying from a sandbox to production? 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.

39. 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?
A. VSCode
B. SFDX CLI
C. Developer Console
D. Change Sets

40. Universal Containers has a Visualforce page that displays a table of every
Container__c being rented by a given Account. Recently this page is failing with a
view state limit because some of the customers rent over 10,000 containers.
What should a developer change about the Visualforce page to help with the page
load errors?
A. Implement pagination with an OffsetController.
B. Implement pagination with a StandardSetController.
C. Use JavaScript remoting with SOQL Offset.
D. Use lazy loading and a transient List variable.

41. Universal Containers decides to use purely declarative development to build out a
new Salesforce application.
Which two options can be used to build out the business logic layer for this
application?
A. Record-Triggered Flow
B. Batch Jobs
C. Remote Actions
D. Validation Rules

42. A custom object Trainer__c has a lookup field to another custom object Gym__c.
Which SOQL query will get the record for the Viridian City Gym and all it's trainers?
A. SELECT ID FROM Trainer__c WHERE Gym_r.Name = 'Viridian City Gym’
B. SELECT ID, (SELECT ID FROM Trainer__c) FROM Gym__C WHERE Name =
'Viridian City Gym’
C. SELECT ID, (SELECT ID FROM Trainers__r) FROM Gym__C WHERE Name =
'Viridian City Gym’
D. SELECT ID, (SELECT ID FROM Trainer__c) FROM Gym__C WHERE Name =
'Viridian City Gym’

43. Which three resources in an Aura component can contain JavaScript functions?
A. Style
B. Renderer
C. Controller
D. Design
E. Helper

44. A developer created a custom order management app that uses an Apex class.
The order is represented by an Order object and an OrderItem object that has a
master-detail relationship to Order. During order processing, an order may be split
into multiple orders.
What should a developer do to allow their code to move some existing OrderItem
records to a new Order record?
A. Add without sharing to the Apex class declaration.
B. Change the master-detail relationship to an external lookup relationship.
C. Create a Junction object between OrderItem and Order.
D. Select the Allow reparenting option on the master-detail relationship.

45. Which three statements are accurate about debug logs?


A. Debug logs can be set for specific users, classes, and triggers.
B. System debug logs are retained for 24 hours.
C. Only the 20 most recent debug logs for a user are kept.
D. Debug log levels are cumulative, where FINE log level includes all events
logged at the DEBUG, INFO, WARN, and ERROR levels.
E. The maximum size of a debug log is 5 MB.

46. What does the Lightning Component framework provide to developers?


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

47. 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?
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.

48. if (isOK == false && theString == 'Hello') {


x = 1;
} else if (isOK == true && theString == 'Hello'){
x=2;
}else if (isOK!= null && theString == 'Hello') {
x = 3;
} else { x = 4
;

}
Based on this code, what is the value of x?
A. 3
B. 2
C. 4

49. Which two actions may cause triggers to fire?


A. Changing a user's default division when the transfer division option is checked
B. Updates to FeedItem
C. Cascading delete operations
D. Renaming or replacing a picklist entry

50. Universal Containers has an order system that uses an Order Number to identify
an order for customers and service agents. Order records will be imported into
Salesforce.
How should the Order Number field be defined in Salesforce?

A. Indirect Lookup
B. External ID and Unique
C. Direct Lookup
D. Lookup
51. A developer created a trigger on a custom object. This custom object also has
some dependent pick lists.
According to the order of execution rules, which step happens first? A.
The original record is loaded from the database.
B. System validation is run for maximum field lengths C.
Old values are overwritten with the new record values.
D. JavaScript validation is run in the browser.

52. 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?
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.

53. 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 s upport these requirements?
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
54. A developer is creating an app that contains multiple Lightning web components.
One of the child components is used for navigation purposes. When a user clicks a
button called Next in the child component, the parent component must be alerted so
it can navigate to the next page.
How should this be accomplished?
A. Update a property on the parent.
B. Call a method in the Apex controller.
C. Fire a notification.
D. Create a custom event.

55. Which annotation exposes an Apex class as a RESTful web service?


A. @RemoteAction
B. @RestResource (urlMapping=’/myService/*’)
C. @HttpInvocable
D. @AuraEnabled(cacheable=true)

56. Universal Containers is building a recruiting app with an Applicant object that
stores information about an individual person and a Job object that represents a job.
Each applicant may apply for more than one job.
What should a developer implement to represent that an applicant has applied for a
job?
A. Junction object between Applicant and Job
B. Lookup field from Applicant to Job
C. Master-detail field from Applicant to Job
D. Formula field on Applicant that references Job

57. 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?
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.

58. Which scenario is valid for execution by unit tests? A.


Execute anonymous Apex as a different user.
B. Generate a Visualforce PDF with getContentAsPDF().
C. Load data from a remote site with a callout.
D. Set the created date of a record using a system method.

59. Developers at Universal Containers (UC) use version control to share their code
changes, but they notice that when they deploy their code to different environments
they often have failures. They decide to set up Continuous Integration (CI).
What should the UC development team use to automatically run tests as part of their
CI process?
A. Salesforce CLI
B. Visual Studio Code
C. Force.com Toolkit
D. Developer Console
60. 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?
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
61. A developer created a trigger on the Account object and wants to test if the
trigger is properly bulkified. The developer team decided that the trigger should be
tested with 200 account records with unique names.
What two things should be done to create the test data within the unit test with the
least amount of code?
A. Use the @isTest (seeAllData = true) annotation in the test class.
B. Use the @isTest(isParallel = true) annotation in the test class.
C. Create a static resource containing test data.
D. Use Test.loadData to populate data in your test methods.
62. A business has a proprietary Order Management System (OMS) that creates
orders from its website and fulfills the orders. When the order is created in the OMS,
an integration also creates an order record in Salesforce and relates it to the contact
as identified by the email on the order. As the order goes through different stages in
the OMS, the integration also updates it in Salesforce.
The business notices that each update from the OMS creates a new order record in
Salesforce.
Which two actions should prevent the duplicate order records from being created in
Salesforce?
A. Use the order number from the OMS as an external ID.
B. Ensure that the order number in the OMS is unique.
C. Use the email on the contact record as an external ID.
D. Write a trigger on the Order object to delete the duplicates.
63. Which three data types can a SOQL query return?
A. Double

B. Long
C. sobject
D. Integer
E. List
64. A developer created a new after insert trigger on the Lead object that creates
Task records for each Lead.
After deploying to production, an existing outside integration that inserts Lead
records in batches to Salesforce is occasionally reporting total batch failures being
caused by the Task insert statement. This causes the integration process in the
outside system to stop, requiring a manual restart.
Which change should the developer make to allow the integration to continue when
some records in a batch cause failures due to the Task insert statement, so that
manual restarts are not needed?
A. Use the Database method with allorNone set to false.
B. Deactivate the trigger before the integration runs.
C. Remove the Apex class from the integration user's profile.

D. Use a try-catch block after the insert statement.


65. Which two statements are true about using the @testSetup annotation in an
Apex test class?
A. Records created in the test setup method cannot be updated in Individual test
methods.
B. In a test setup method, test data is inserted once and made available for all
test methods in the test class.
C. A method defined with the @testSetup annotation executes once for each test
method in the test class and counts towards system limits.
D. The testSetup annotation is not supported when the @isTest(SeeAllData=True)
annotation is used.

----------END-----------
SET5
1 . A Salesforce administrator used Flow Builder to create a flow named "accountOnboarding". The
flow must be used inside an Aura component.
Which tag should a developer use to display the flow in the component?
A . lightning : flow
B . lightning – flow
C . aura : flow
D . aura - flow

2 . 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?

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.

3 of 65. What is the result of the following code snippet?

public void doWork (Account acct) {


for (Integer i=0; i <= 200; i++) {
insert acct;
}
}
A. 0 Accounts are inserted.
B. 1 Account is inserted.
C. 200 Accounts are inserted.
D. 201 Accounts are inserted.

4 . 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)
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 asynchronous 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.

5 . A developer must perform a complex SOQL query that joins two objects in a Lightning
component.
How can the Lightning component execute the query?
A. Write the query in a custom Lightning web component wrapper and invoke from the Lightning
component.
B . Invoke an Apex class with the method annotated as @AuraEnabled to perform the query.
C. Use the Salesforce Streaming API to perform the SOQL query
D. Create a flow to execute the query and invoke from the Lightning component.

6 . Which two operations affect the number of times a trigger can fire? (Choose 2 answers)
A. Criteria-based sharing calculations
B. Email messages
C. Roll-up summary fields
D. After-save record-triggered flow

7 . Which two are best practices when it comes to Aura component and application event handling?
(Choose 2 answers)
A. Try to use application events as opposed to component events.
B. Reuse the event logic in a component bundle, by putting the logic in the helper.
C. Use component events to communicate actions that should be handled at the application level.
D. Handle low-level events in the event handler and re-fire them as higher-level events.

8 of 65. What are three considerations when using the @InvocableMethod annotation in Apex?
(Choose 3 answers)
A. Only one method using the @InvocableMethod annotation can be defined per Apex class.
B. A method using the @InvocableMethod annotation can have multiple input parameters.
C. A method using the @InvocableMethod annotation must be declared as static.
D. A method using the @InvocableMethod annotation must define a return value.
E. A method using the @InvocableMethod annotation can be declared as Public or Global.

9 . Managers at Universal Containers want to ensure that only decommissioned containers are able
to be deleted in the system. To meet the business requirement a Salesforce developer adds
"Decommissioned” as a picklist value for the Status_c custom field within the Container_c object.

Which two approaches could a developer use to enforce only Container records with a status of
"Decommissioned" can be deleted? (Choose 2 answers)
A Before record-triggered flow
B. Apex trigger
C. After record-triggered flow
D. Validation rule
10 of 65. Which two settings must be defined in order to update a record of a junction object?
( Choose 2 answers )
A. Read/Write access on the secondary relationship
B. Read/Write access on the primary relationship
C. Read/Write access on the junction object
D. Read access on the primary relationship

11 of 65. A developer wrote Apex code that calls out to an external system using REST API.
How should a developer write the test to prove the code is working as intended?

A. Write a class that implements HTTPCalloutMock.


B. Write a class that extends WebserviceMock.
C. Write a class that implements webserviceMock.
D. Write a class that extends HTTPCalloutMock.

12 . Universal Containers wants to assess the advantages of declarative development versus


programmatic customization for specific use cases in its Salesforce implementation.
What are two characteristics of declarative development over programmatic customization?
(Choose 2 answers)
A. Declarative development does not require Apex test classes.
B. Declarative development has higher design limits and query limits.
C. Declarative development can be done using the Setup menu.
D. Declarative code logic does not require maintenance or review.

13. How is a controller and extension specified for a custom object named "Notice" on a Visualforce
page?
A. apex:page standardController="Notice_c" extensions="myControllerExtension"
B. apex:page controllers="Notice_c, myControllerExtension"
C. apex:page Notice extends="myControllerExtension"
D. apex:page controller "Notice_c" extensions="myControllerExtension"

14. How does the Lightning Component framework help developers implement solutions faster?
A. By providing an Agile process with default steps
B. By providing code review standards and processes
C. By providing change history and version control
D. By providing device-awareness for mobile and desktops

15 . Universal Containers wants a list button to display a Visualforce page that allows users to edit
multiple records.
Which Visualforce feature supports this requirement?
A. Standard Controller with Custom List Controller extension
B. Custom List Controller with recordSetVar page attribute
C. Controller Extension and <apex:ltatautton> tag
D. Standard controller and the recordSetVar page attribute

16. Universal Containers wants to ensure that all new leads created in the system have a valid email
address. They have already created a validation rule to enforce this requirement, but want to add an
additional layer of validation using automation.
What would be the best solution for this requirement?
A. Submit a REST API Callout with a ISON payload and validate the fields on a third party system
B. Use an Approval Process to enforce the completion of a valid email address using an outbound
message action.
C. Use before-save Apex tripper on the Lead object to validate the email address and display an
error message if it is invalid
D. Use a custom Lightning Web component to make a callout to validate the fields on a third party
systems

17. 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?
A. Developer sandboxes
B. Full Copy sandboxes
C. Developer orgs
D. Scratch orgs

18 . A team of many developers work in their own individual orgs that have the same configuration
as the production org.
Which type of org is best suited for this scenario?
A. Developer Sandbox
B. Full Sandbox
C. Developer Edition
D. Partner Developer Edition

19 . A developer must provide custom user interfaces when users edit a Contact in either Salesforce
Classic or Lightning Experience.
What should the developer use to override the Contact's Edit button and provide this functionality?
A. A Lightning component in Salesforce Classic and a Lightning component in Lightning Experience
B. A Lightning page in Salesforce Classic and a Visualforce page in Lightning Experience
C. A Visualforce page in Salesforce Classic and a Lightning page in Lightning Experience
D. A Visualforce page in Salesforce Classic and a Lightning component in Lightning Experience

20 . Which code statement includes an Apex method named updateAccounts Accounts in the class
AccountController for use in a Lightning web component?
A. import updateAccounts from Account Controller’;
B .import updateAccounts from ‘salesforce/apex/Account Controller’;
C .import updateAccounts from ‘Account Controller.updateAccounts’;
D .import updateAccounts from @salesforce/apex/Account Controller.updateAccounts’;
21 . A developer needs to allow users to complete a form on an Account record that will create a
record for a custom object.
The form needs to display different fields depending on the user's job role. The functionality should
only be available to a small group of users.
> Which three things should the developer do to satisfy these requirements?
(Choose 3 answers)
A. Add a Dynamic Action to the Users' assigned Page Layouts.
B. Create a Lightning web component. []
C. Create a Custom Permission for the users.
D. Add a Dynamic Action to the Account Record Page.
E. Create a Dynamic Form.

22. A developer needs to prevent the creation of request records when certain conditions exist in the
system. A RequestLogic class exists to checks the conditions. What is the correct implementation?

A. Trigger RequestTrigger on Request (before insert) {


RequestLogic.validateRecords {trigger.new};
}
B. Trigger RequestTrigger on Request (before insert) {
if (RequestLogic.isvalid{Request})
Request.addError {'Your request cannot be created at this time.'};
}
C. Trigger RequestTrigger on Request (after insert) {
if (RequestLogic.isValid{Request})
Request.addError {'Your request cannot be created at this time.'};
}
D. Trigger RequestTrigger on Request (after insert) {
RequestLogic.validateRecords {trigger.new};
}

23 . For which three items can a trace flag be configured?


Choose 3 answers
A. Apex Class
B. Flow
C. User
D. Visualforce
E. Apex Trigger
24 . Which exception type cannot be caught ?
A. A custom Exception
B. Limit Exception
C. CalloutException
D. NoAccessException

25 . What should a developer do to check the code coverage of a class after running all tests?
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 on the Apex Classes page.

26 . A developer creates a new Apex trigger with a helper class, and writes a test class that only
exercises 95% coverage of the new Apex helper class.
Change Set deployment to production fails with the test coverage warning:
"Test coverage of selected Apex Trigger is 0%, at least 1% test coverage is required."
What should the developer do to successfully deploy the new Apex trigger and helper class?
A. Increase the test class coverage on the helper class.
B. Create a test class and methods to cover the Apex trigger.
C. Remove the failing test methods from the test class.
D. Run the tests using the 'Run All Tests' method

27 . What are three capabilities of the <ltng : require> tag when loading JavaScript resources in Aura
components? ( Choose 3 answers )
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

28 . A custom picklist field, Food_Preference_c, exists 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 optimal 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" to True.
B. Write an Apex trigger to ensure a value is selected.
C. Mark the field as Required on the object's page layout.
D. Mark the field as Required on the field definition.

29 . A company decides to implement a new process where every time an Opportunity is created, a
follow up Task should be created and assigned to the Opportunity Owner.
What is the most efficient way for a developer to implement this?
A. Apex trigger on Task
B. Task actions
C. Auto-launched flow on Task
D. Record-triggered flow on Opportunity
30 . 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:

What are two ways the developer can update the method to prevent a SOQL injection attack?
(Choose two.)
 A. Use the @ReadOnly annotation and the with sharing keyword on the class.
 B. Use the escapeSingleQuotes method to sanitize the parameter before its use.
 C. Use a regular expression expression on the parameter to remove special characters.
 D. Use variable binding and replace the dynamic query with a static SOQL.

31 . What are two benefits of using External IDs? ( Choose 2 answers)


A . An External ID is indexed and can improve the performance of SOQL queries.
B . An External ID field can be used to reference a unique ID from another, external system.
C . An External ID can be a formula field to help create a unique key from two fields in Salesforce.
D . An External ID can be used with Salesforce Mobile to make external data visible.

32 . What are two characteristics related to formulas? (Choose 2 answers.)


A. Fields that are used in a formula field can be deleted or edited without the formula.
B. Formulas are calculated at runtime and are not stored in the database.
C. Formulas can reference values in related objects.
D. Formula can reference themselves.

33 . What should a developer use to script the deployment and unit test execution as part of
continuous integration?
A . Developer Console
B . Execute Anonymous
C . Salesforce CLI
D . VS Code

34 of 65. What are two considerations for deploying from a sandbox to production?
Choose 2 answers
A. Urist tests must have calls to the System.assert method.
B. All triggers must have at least one line of test coverage.
C At least 75% of Apex code must be covered try unit tests.
D. Should deploy during business hours to ensure feedback can be quickly addressed.
35 . What is the result of the following code?
Account a = new Account () ;
Database.insert(a, false);
A. The record will not be created and no error will be reported.
B. The record will not be created and a exception will be thrown.
C. The record will be created and a message will be in the debug log.
D. The record will be created and no error will be reported.

36 . A developer is creating a page that allows users to create multiple Opportunities. The developer
is asked to verify the current user’s default Opportunity record type, and set certain default values
based on the record type before inserting the record.
How can the developer find the current user’s default record type?

A . Use the Schema.userInfo.Opportunity.getDefaultRecordType() method.

B. Query the Profile where the ID equals userInfo.getProfileID() and then use the
profile.Opportunity.getDefaultRecordType() method.

C. Create the opportunity and check the opportunity.recordType, which will have the record ID of the
current user’s default record type, before inserting.

D. Use Opportunity.SObjectType.getDescribe().getRecordTypeInfos() to get a list of record types, and


iterate through them until isDefaultRecordTypeMapping() is true.

37 . The Account object in an organization has a master-detail relationship to a child object called
Branch. The following automations exist:
 Roll-up summary fields
 Custom validation rules
 Duplicate rules
A developer created a trigger on the Account object.
Which two things should the developer consider while testing the trigger code? (choose 2 answers)
A .Rollup summary fields can cause the parent record to go through Save.
B. Duplicate rules are executed once all DML operations commit to the database.
C .The trigger may fire multiple times during a transaction
D .The validation rules will cause the trigger to fire again

38 . A developer has a single custom controller class that works with a Visualforce Wizard to support
creating and editing multiple subjects. The wizard accepts data from user inputs across multiple
Visualforce pages and from a parameter on the initial URL.
Which three statements are useful inside the unit test to effectively test the custom controller?
Choose 3 answers
A. public ExtendedController(ApexPages StandardController cntrl) { }
B. Test.setCurrentPage(pageRef);
C. ApexPages.CurrentPage().getParameters().put('input\', 'TestValue');
D. String nextPage - controller.save().getUrl();
E. insert pageRef.
39 . A developer is designing a new application on the Salesforce platform and wants to ensure it can
support multiple tenants effectively.
Which design framework should the developer consider to ensure scalability and maintainability?
A. Flux (view, action, dispatcher, and store)
B. Waterfall Model
C. Agile Development
D. Model-View-Controller (MVC)

40 . A developer at AW Computing is tasked to create the supporting test class for a programmatic
customization that leverages records stored within the custom object, Pricing_Structure__c. AW
Computing has a complex pricing structure for each item on the store, spanning more than 500
records.
Which two approaches can the developer use to ensure Pricing_Structure__c records are available
when the test class is executed? (Choose two.)
A. Use the Test.loadTest() method.
B. Use the @IsTest(SeeAllData=true) annotation.
C. Use a Test Data Factory class.
D. Use without sharing on the class declaration.

41 . Given the following Apex statement:


Account myAccount [SELECT Id, Name FROM Account];

What occurs when more than one Account is returned by the SOQL query?
A. The variable, myaccount, is automatically cast to the List data type
B. An unhandled exception is thrown and the code terminates.
C The query fails and an error is written to the debug log.
D. The first Account returned is assigned to myaccount.

42 . An org has an existing Visual Flow that creates an Opportunity with an Update Records element.
A developer must update the Visual Flow to also create a Contact and store the created Contact's ID
on the Opportunity.
Which update should the developer make in the Visual Flow?
A. Add a new Create Records element.
B. Add a new Quick Action (of type Create) element.
C. Add a new Update Records element.
D. Add a new Get Records element.

43 . Universal Containers wants to back up all of the data and attachments in its Salesforce org once
month. Which approach should a developer use to meet this requirement?
A . Use the Data Loader command line.
B . Create a Schedulable Apex class.
C . Schedule a report.
D . Define a Data Export scheduled job.

44 . What should a developer use to fix a Lightning web component bug in a sandbox?
A. VS Code
B. Developer Console
C. Force.com IDE
D. Execute Anonymous

45 . A developer must write an Apex method that will be called from a Lightning component. The
method may delete an Account stored in the accountRec variable.
Which method should a developer use to ensure only users that should be able to delete Accounts
can successfully perform deletions?
A. accountRec.isDeletable()
B. accountRec.sObjectType.isDeletable()
C. Account.isDeletable()
D. Schema.sObjectType.Account.isDeletable()

46 . A lead developer creates an Apex interface called "Laptop". Consider the following code snippet:

How can a developer use the Laptop Interface within the SilverLaptop class ?
A. @Extends(class=Laptop'') public class SilverLaptop
B. public class SilverLaptop extends Laptop
C. @Interface (class=''Laptop'') public class SilverLaptop
D. public class Silverlaptop implements Laptop

47 . A lead developer creates a virtual class called "OrderRequest". Consider the following code
snippet:
public class CustomerOrder(
//code implementation
}
How can a developer use the OrderRequest class within the CustomerOrder class?

A . Extends (class="OrderRequest")
public class CustomerOrder

B . public class CustomerOrder extends OrderRequest


C. public class CustomerOrder implements Order

D. Implements (class="OrderRequest")
public class CustomerOrder
48 . 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. SELECT Lead.Id, Lead.Name, Account.Id, Account.Name, Contact.Id, Contact.Name FROM Lead,


Account, Contact WHERE CompanyName = ‘Universal Containers’
B. FIND ‘Universal Containers’ IN Name Fields RETURNING lead(id, name), account (id, name),
contact(id, name)
C. FIND ‘Universal Containers’ IN CompanyName Fields RETURNING lead(id, name), account (id,
name), contact(id, name)
D. SELECT lead(id, name), account (id, name), contact(id, name) FROM Lead, Account, Contact
WHERE Name = ‘Universal Containers’

49 . 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?
A. Write a Process Builder that links the custom object to the Opportunity.
B. Write a trigger on the child object and use an aggregate function to sum the amount for all related
child objects under the Opportunity
C. Write a trigger on the child object and use a red-black tree sorting to sum the amount for all
related child objects under the Opportunity.
D. Use the Streaming API to create real-time roll-up summaries.

50 . A primaryid_c custom field exists on the candidate_c custom object. The filed is used to store
each candidate's id number and is marked as Unique in the schema definition.

As part of a data enrichment process. Universal Containers has a CSV file that contains updated data
for all candidates in the system, the file contains each Candidate's primary id as a data point.
Universal Containers wants to upload this information into Salesforce, while ensuring all data rows
are correctly mapped to a candidate in the system.

Which technique should the developer implement to streamline the data upload?
A. Create a Process Builder on the Candidate_c object to map the records.
B. Create a before Insert trigger to correctly map the records.
C. Update the primaryid__c field definition to mark it as an External Id
D. Upload the CSV into a custom object related to Candidate_c.

51 . A Developer Edition org has five existing accounts. A developer wants to add 10 more accounts
for testing purposes. The following code is executed in the Developer Console using the Execute
Anonymous window:
Account myAccount = new Account (Name = 'MyAccount' ) ;
insert myAccount; Integer x = 1;
List<Account> newAccounts = new List<Account> () ;
do {
Account acet = new Account (Name = *New Account » + x++);
newAccounts.add (acct) ;
} while (x < 10);
How many total accounts will be in the org after this code is executed?
A. 5
в. 6
C. 10
D. 15

52 of 65. What are two considerations for running a flow in debug mode? Choose 2 answers
A. Callouts to external systems are not executed when debugging a flow.
B. DML operations will be rolled back when the debugging ends.
C. Input variables of type record cannot be passed into the flow.
D. Clicking Pause or executing a Pause element closes the flow and ends debugging.

53 of 65. 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?
A. Screen-based flow
B. Approval process
C. Apex trigger
D. Lightning Component

54 . A custom Visualforce controller calls the ApexPages, addMessage () method, but no messages
are rendering on the page. Which component should be added to the Visualforce page to display the
message?
A. Capeximessage for="info"/>
В. aрех: pageMessages />
C «apex:pageMessage severity-"into* />
D. «apex:facet name-"messages" />

55. Since Aura application events follow the traditional publish-subscribe model, which method is
used to fire an event?
A. fire()
B. aegisterEvent ()
C. fireBrent ()
D. emit()
56 . A developer must troubleshoot to pinpoint the causes of performance issues when a custom
page loads in their org. Which tool should the developer use to troubleshoot query performance?
A. Setup Menu
B. AppExchange
C. Visual Studio Code IDE
D. Developer Console

58 . What does the Lightning Component framework provide to developers?


A. Extended governor limits for applications
B. Prebuilt component that can be reused.
C. Templates to create custom components.
D. Support for Classic and Lightning UIS

59 . 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?
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.

60 . What are three ways for a developer to execute tests in an org? >> Choose 3 answers
A. Bulk API
B. Salesforce DX
C. Tooling API
D. Setup Menu
E. Metadata API

61 . When importing and exporting data into Salesforce, which two statements are true?
Choose 2 answers

A. Bulk API can be used to bypass the storage limits when importing large data volumes in
development environments.
B. Data import wizard is an application that is installed on your computer.
C. Bulk API can be used to import large data volumes in development environments without
bypassing the storage limits.
D. Developer and Developer Pro sandboxes have different storage limits.

62 . A developer must implement a CheckPaymentProcessor class that provides check processing


payment capabilities that adhere to what is defined for payments in the PaymentProcessor interface.
public interface PaymentProcessor { void pay(Decimal amount);
}
Which is the correct implementation to use the PaymentProcessor interface class?

A. public class CheckPaymentProcessor implements PaymentProcessor { public void pay(Decimal


amount);
B. public class CheckPaymentProcessor implements PaymentProcessor { public void pay(Decimal
amount){}
C. public class CheckPaymentProcessor extends PaymentProcessor { public void pay(Decimal
amount){}
D. public class CheckPaymentProcessor extends PaymentProcessor { public void pay(Decimal
amount);

63 . A Developer wants to get access to the standard price book in the org while writing a test class
that covers an OpportunityLineItem trigger.
Which method allows access to the price book?
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 Test.loadData() and a Static Resource to load a standard price book.
D. Use @TestVisible to allow the test method to see the standard price book.

64 . A developer must create a Lightning component that allows users to input Contact record
information to create a Contact record, including a Salary__c custom field.
What should the developer use, along with a lightning-record-edit-form, so that Salary__c field
functions as a currency input and is only viewable and editable by users that have the correct field
level permissions on Salary__c?
A.

B.

C.

D.

65 . Universal Containers decides to use exclusively declarative development to build out a new
Salesforce application.
Which three options should be used to build out the database layer for the application?
>>>Choose 3 answers
A. Custom objects and fields
B. Triggers
C. Roll-up summaries
D. Relationships
E. Flows

SET 6
1. Given the following Anonymous block: List<Case>
casesToUpdate = new List<Case>();
for(Case thiscase : [SELECT Id, Status FROM Case LIMIT 50000]){ thisCase.Status
= 'Working’:
casesToUpdate.add(thisCase);
} try{
Database.update(casesToUpdate, false):
}catch (Exception e) (
System.debug(e.getMessage());
}
What should a developer consider for an environment that has over 10,000 Case
records?
A. The try-catch block will handle any DML exceptions thrown.
B. The try-catch block will handle exceptions thrown by governor limits.
C. The transaction will fall due to exceeding the governor limit.
D. The transaction will succeed and changes will be committed.

2. A developer wrote Apex code that calls out to an external system using REST API.
How should a developer write the test to prove the code is working as intended? A.
Write a class that extends WebserviceMock.
B. Write a class that implements HTTPCalloutMoak.
C. Write a class that extends HTTPCalloutMoak.
D. Write a class that implements WebServiceMock.
3. How can a developer check the test coverage of autolaunched Flows before
deploying them in a change set?

A. Use SOQL and the Tooling API.


B. Use the Code Coverage Setup page.
C. Use the ApexTestResult class.
D. Use the low Properties page.

4. Universal Containers is developing a new Lightning web component for their


marketing department. They want to ensure that the component is fine tuned and
provides a seamless user experience.
What are some benefits of using the Lightning Component framework?
A. Automatic support for accessibility standards
B. Better performance due to client-side rendering
C. Easy Integration with third-party libraries
D. Compatibility with all web browsers

5. Universal Containers has developed custom Apex code and Lightning Components
in a Sandbox environment. They need to deploy the code and associated
configurations to the Production environment.
What is the recommended process for deploying the code and configurations to
Production?
A. Use Saleforce CLI to deploy the Apex code and Lightning Components:
B. Use the Force.com IDF to deploy the Apex code and Lightning Components,
C. Lise a change set to deploy the Apex code and Lightning Components.
D. Use the Ant Migration Tool to deplay the Apex coda and Lightning Components

6. A developer has the following requirements:


• Calculate the total amount on an Order.
• Calculate the line amount for each Line Item based on quantity selected and price.
• Move Line Items to a different Order if a Line Item is not in stock.
Which relationship Implementation supports these requirements on its own? A.
Order has a re parentable lookup field to Line Item.
B. Line Item has a re parentable master detail field to Order.
C. Line Item has a re-parentable lookup field to Order.
D. Order has a re-parentable master-detail field to Line Item.

7. 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? A. 2
B. 3
C. 4
D. 1

8. 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 Itern 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? A.
Use a MAX Roll-Up Summary field on the latest availability data fields.
B. Use a CETLING formula on each of the latest availability date fleids.
C. Use a DAYS formula on each of the availability data fields and a COUNT Roll Up
Summary field on the Order
D. Uso a LATEST formula on each of the latest availability date fields.
9. A large corporation stores Orders and Line Items in Salesforce for different lines of
business. Users are allowed to see Orders across the entire organization, but, for
security purposes, should only be able to see the Line Items for Orders in their line of
business.
Which type of relationship should be used between Line Items and Orders?
A. Lookup
B. Indirect Lookup
C. Direct Lookup
D. Master-Detail

10. A developer created a custom order management app that uses an Apex class.
The order is represented by an Order object and an OrderItem object that has a
master-detail relationship to Order. During order processing, an order may be split
into multiple orders.
What should a developer do to allow their code to move some existing OrderItem
records to a new Order record?
A. Change the master-detail relationship to an external lookup relationship.
B. Select the Allow reparenting option on the master-detail relationship.
C. Add without sharing to the Apex class declaration.
D. Create a function object between Orderitem and Order.

11. A developer is creating an app that contains multiple Lightning web components.
One of the child components is used for navigation purposes. When a user clicks a
button called Next in the child component, the parent component must be alerted so
it can navigate to the next page.
How should this be accomplished? A.
Create a custom event.
B. Call a method in the Apex controller.
C. Update a property on the parent.
D. Fire a notification

12. Universal Containers wants Opportunities to no longer be editable when reaching


the Closed/Won stage.
How should a developer accomplish this? A.
Use Flow Builder.
B. Use a validation rule.
C. Use the Process Automation settings.
D. Mark ficids as read only on the page layout.

13. 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? A.
Include<apex: messages> on the Visualforce page.
B. Perform the DML using the Database.upsert() method.
C. Use a try/catch with a custom exception class.
D. Add custom controller attributes to display the message.

14. Universal Containers wants to ensure that all new leads created in the system
have a valid email address. They have already created a validation rule to enforce this
requirement, but want to add an additional layer of validation using Apex code.
What would be the best solution for this requirement?
A. Use a trigger on the Lead object to validate the email address and display an error
message if it is invalid.
B. Create a time-based workflow rule that updates the email address if it is invalid.
C. Submit a REST API Callout with a JSON payload and validate the fields on a third
party system.
D. Use a Process Builder to validate the email address and display an error message it
it is invalid.

15. 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?
A. Scratch orgs
B. Developer sandboxes
C. Developer orgs
D. Full Copy sandboxes

16. Universal Containers uses Service Cloud with a custom field, Stage_c, on the Case
object.
Management wants to send a follow-up email reminder to the Case Owner 6 hours
after the Stage_c field is set to "Waiting on Customer". The Salesforce Administrator
wants to ensure the solution used is bulk safe.
Which automation tool should a developer recommend to meet these business
requirements?
A. Entitlement Process
B. Record-Triggered Flow with a Scheduled Path
C. Scheduled Flow
D. Einstein Next Best Action
17. 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?
A. Use the Data Import Wizard to import the data and set up field-level security
to restrict access to sensitive fields.
B. Use the Salesforce CLI to import the data and set up user permissions to
restrict access to sensitive data.
C. Use a third-party tool to encrypt the sensitive data before imparting it into
Salesforce.
D. Use the Apex Data Loader to import the data and write Apex code to handle
security and access control.

18. What does the Lightning Component framework provide to developers?


A. Prebuilt components that can be reused
B. Extended governor limits for applications C. Templates to
create custom components.
D. Support for Classic and Lightning UIs.

19. Which scenario is valid for execution by unit tests? A.


Load data from a remote site with a callout.
B. Set the created date of a record using a system method.
C. Execute anonymous Apex as a different user.
D. Generate a Visualforce PDF with getContentAsPDF().

20. 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?
A Add a new Update Records clement.
B. Add a new Roll Back Records clement.
C. Add a new Get Records element.
D. Add a new Create Records element.

21. A developer created this Apex trigger that calls Myclass.myStaticMethod:


trigger myTrigger on Contact (before insert){
Myclass.myStaticMethod(trigger.now);

}
The developer creates a test class with a test method that calls
myclass.myStaricMethod 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?
A. The deployment passes because the apex code has the required >75% code
coverage.
B. The deployment fails because no assertions were made in the test method.
C. The deployment fails because the apex trigger has no code coverage.
D. The deployment passes because both classes and the trigger were included in the
deployment.

22. In the Lightning UI, where should a developer look to find information about a
Paused Flow Interview?
A. In the Paused Interviews section of the Apex lex Queue
B. In the system debug log by filtering on Paused Flow Interview
C. On the Paused and failed Flow Interviews page under Setup Process Automation
D. On the Paused Flow Interviews related list for a given record.

23. A Primaryid_c custom field exists on the Candidate_c custom object. The field is
used to store each candidate's id number and is marked as Unique in the schema
definition.
As part of a data enrichment process, Universal Containers has a CSV file that
contains updated data for all candidates in the system. The file contains each
Candidate's primary id as a data point. Universal Containers wants to upload this
information into Salesforce, while ensuring all data rows are correctly mapped to a
candidate in the system.
Which technique should the developer implement to streamline the data upload?
A Upload the CSV into a custom object related to Candidate_c. B.
Create a before insert trigger to correctly map the reconds.
C. Create a before save now to correctly map the records.
D. Update the Primaryid_c held definition to mark it as an External Id.

24. Given the following Apex statement:


Account myAccount = [SELECT Id, Name FROM Account];
What occurs when more than one Account is returned by the SOQL query? A.
The variable, myAccount, is automatically cast to the list data type.
B. The first Account returned is assigned to mγAccount.
C. The query fails and an error is written to the debug log.
D. An unhandled exception is thrown and the code terminates.

25. What is a benefit of developing applications in a multi-tenant environment?


A. Enforced unit testing and code coverage best practices
B. Preconfigured storage for big data
C. Unlimited processing power and memory
D. Access to predefined computing resources

26. Which action may cause triggers to fire?


A. Changing user's default division when the transfer division option is checked
B. Cascading delete operations.
C. Updates to Feed Items
D. Renaming or replacing a picklist entry.

27. What should a developer use to script the deployment and unit test execution as
part of continuous Integration?
A. Developer Console
B. Execute Anonymous
C. Salesforce CLI
D. VS Code

28. A developer needs to have records with specific field values in order to test a new
Apex class.
What should the developer do to ensure the data is available to the test? A.
Use Test.loadData() and reference a JSON file In Documents.
B. Use SOQL to query the org for the required data
C. USE Anonymous Apex to create the required data
D. Use Test.loadData() and reference a CSV the in a static resource.

29. A developer created these three Rollup Summary fields in the custom object,
Project_c :
Total_Timesheets_c
Total_Approved_Timesheets_c
Total Rojected Timesheet_c
The developer is asked to create a new field that shows the ratio between rejected
and approved timesheets for a given project.
Which should the developer use to implement the business requirement in order to
minimize maintenance overhead?
A. Roll-up summary field
B. Formula field
C. Apex trigger
D. Record-triggered flow

You might also like