Refer to the test method below:
The test method calls an @future method that increments the
Number_of_Times_Viewed__c value. The assertion is failing because the
Number of Times Viewed_c equals 0.
What is the optimal way to fix this?
The Salesforce admin et Cloud Kicks created a custom object called Region_c to store all postal zip codes in the United States and the Cloud Kicks sales region the zip code belongs to.
Cloud Kicks wants a trigger on the Lead to populate the Region based on the Lead's zip code.
Which code segment is the most efficient way to fulfill this request?
A)
B)
C)
D)
A company needs to automatically delete sensitive information after seven years.
This could delete almost a million records every day.
How can this be achieved?
A page throws an ‘Attempt to dereference a null object’ error for a Contact.
What change in the controller will fix the error?
Universal Containers has an Apex trigger on Account that creates an Account Plan record when an Account is marked as a Customer.
Recently a record-triggered flow was added so that whenever an Account is marked as a Customer, a "Customer Since’ date field is updated with today's date. Since the addition of the flow, two Account Plan records are created whenever the Account is marked as a Customer.
What might cause this to happen?
A company wants to run different logic based on an Opportunity's record type.
Which code segment handles this request and follows best practices?
A)
B)
C)
D)
In an organization that has multi-currency enabled, a developer Is tasked with building a Lighting component that displays the top ten Opportunities most recently accessed by the logged in user. The developer must ensure the Amount and LastModifiedDate field values are displayed according to the user's locale.
What is the most effective approach to ensure values displayed respect the user's locale settings?
The use of the transient keyword in Visualforce page controllers helps with which common performance issue?
Universal Containers analyzes a Lightning web component and its Apex controller
class that retrieves a list of contacts associated with an account. The code snippets
are as follows:
Based on the code snippets, what change should be made to display the contacts’ mailing addresses in the Lightning web component?
Universal Containers (UC) has enabled the translation workbench and has translated picklist values. UC has a custom multi-select picklist field, Product__c, on the Account object that allows sales reps to specify which of UC’s products an Account already has. A developer is tasked with writing an Apex method that retrieves Account records, including the Product_c field.
What should the developer do to ensure the value of Products__c is in the current user's language?
A company has reference data stored in multiple custom metadata records that represent default information and delete behavior for certain geographic regions.
When a contact is inserted, the default information should be set on the contact from the custom metadata records based on the contact's address information.
Additionally, if a user attempts to delete a contact that belongs to a flagged region, the user must get an error message.
Depending on company personnel resources, what are two ways to automate this?
Choose 2 answers
A developer is working on an integration between Salestorce and an external system. The integration requires sending a large amount of data to the external systern, which can cause long response times and timeouts.
To optimize the performance and avoid timeouts, which technique should be used?
Universal Containers wants to notify an external system in the event that an unhandled exception occurs when their nightly Apex batch job runs.
What is the appropriate publish/subscribe logic to meet this requirement?
When developing a Lightning web component, which setting displays lightninglayout-items im one column on small devices, such as mobile phones, and in two
columns on tablet-size and desktop-size screens?
Business rules require a Contact ta always be created when a new Account is created.
What can be used when developing a custom screen to ensure an Account is not created if the creation of the Contact fails?
Universal Containers wants to notify an external system, in the event that an unhandled exception occurs, by publishing a custom event using Apex.
What is the appropriate publish/subscribe logic to meet this requirement?
A Visualforce page needs to make a callout to get billing information and tax information from two different REST endpoints. The information needs to be
displayed to the user at the same time and the return value of the billing information contains the input for the tax information callout. Each endpoint might take up to two minutes to process.
How should a developer implement the callouts?
Refer to the Aura component below:
A developer receives complaints that the component loads slowly.
Which change can the developer implement to make the component perform faster?
Which three approaches should a developer implement to obtain the best performance for data retrieval when building a Lightning web component? Choose 3 answers
Which two queries are selective SOQL queries and can be used for a large data set of 200,000 Account records?
Choose 2 answers
A developer created a Lightning web component for the Account record page that displays the five most recently contacted Contacts for an Account. The Apex method,
Contacts, returns a list of Contacts and will be wired to a property in the component.
Which two lines must change in the above code to make the Apex method able to be wired?
Choose 2 answers
A developer is responsible for formulating the deployment process for a Salesforce project. The project follows a source-driven development approach, and the developer wants to ensure efficient deployment and version control of the metadata changes.
Which tool or mechanism should be utilized for managing the source-driven deployment process?
A developer is creating a page in App Builder that will be used in the Salesforce mobile app.
Which two practices should the developer follow to ensure the page operates with optimal performance?
Choose 2 answers
A developer has a requirement to query three fields (Id, Name, Type) from an Account; and first and last names for all Contacts associated with the Account.
Which option is the preferred, optimized method to achieve this for the Account named ‘Ozone Electronics’?
A)
B)
C)
D)
Universal Containers ne=ds to integrate with several external systems. The process Is Initiated when a record Is created in Salesforce, The remote systems do not require Salesforce to wait for a response before continuing.
What is the recommended best solution to accomplish this?
Universal Containers stores user preferences in a hierarchy custom setting,
user Prefs_c, with a checkbox field, show _help co. Company-level defaults are
stored at the organizational level, but may be overridden at the user level. If a user
has not overridden preferences, then the defaults should be used.
How should the show_Help_ c preference be retrieved for the current user?
A software company uses a custom object, Defact__c, to track defects in their
software. Defect__c has organization-wide defaults set to private. Each Defect_ c
has a related list of Reviewer < records, each with a lookup field to User that is
used to indicate that the User will review the defect__c.
What should be used to give the User on the Reviewer_c record read only access
to the Defect__c record on the Reviewer_c record?
A developer is asked to replace the standard Case creation screen with a custom screen that takes users through a wizard before creating the Case. The org only has users running Lightning Experience.
What should the developer override the Case New Action with to satisfy the requirements?
Universal Containers wants to use a Customer Community with Customer Community Plus licenses to allow their customers access to track how many containers they have rented and when they are due back. Universal Containers uses a Private sharing model for External users, Many of their customers are multi-national corporations with complex Account hierarchies. Each account on the hierarchy represents a department within the same business,
One of the requirements is to allow certain community users within the same
Account hierarchy to see several departments’ containers, based on a custom
junction object that relates the Contact to the various Account records that
represent the departments.
Which solution solves these requirements?
A developer is debugging an Apex-based order creation process that has a requirement to have three savepoints, SP1, SP2, and 5P3 {created in order), before the final execution of the process.
During the final execution process, the developer has a routine to roll back to SP1 for a given condition. Once the condition is fixed, the code then calls 2 roll back to SP3 to continue with final execution. However, when the roll back to SP3 is called, a Funtime error occurs.
Why does the developer receive a runtime error?
A developer is developing a reusable Aura component that will reside on an sObject Lightning page with the following HTML snippet:
How can the component"5 controller get the context of the Lightning page that the sObject is on without requiring additional test coverage?
There are user complaints about slow render times of a custom data table within a Visualforce page that loads thousands of Account records at once.
What can a developer do to help alleviate such issues?
A developer wrote the following method to find all the test accounts in the org:
What should be used to fix this failing test?
Consider the above trigger intended to assign the Account to the manager of the Account's region,
Which two changes should a developer make in this trigger to adhere to best practices?
A corporation has many different Salesforce orgs, with some different objects and some common objects, and wants to build a single Java application that can create, retrieve, and update common object records in all of the different orgs.
Which method of integration should the application use?
As part of their quoting and ordering process, a company needs to send POFs to their document storage system's REST endpoint that supports OAuth 2.0. Each Salesforce user must be individually authenticated with the document storage system to send the PDF.
What is the optimal way for a developer to implement the authentication to the REST endpoint?
A company has a custom object, Order__c, that has a custom picklist field, Status__c, with values of ‘New,' 'In Progress,’ or ‘Fulfilled’ and a lookup field,
Contact__c, to Contact.
Which SOQL query will return a unique list of all the Contact records that have no ‘Fulfilled’ Orders?
A)
B)
C)
D)
A developer wrote a class named asccuntRisteryManager that relies on field history tracking. The class has a static method called getaccountHistory that Lakes in an Account as a parameter and returns a list of associated accountHistory object records.
The following test fails:
What should be done to make this test pass?
Refer to the markup below:
A Lightning web component displays the Account name and two custom fields out of
275 that exist on the abject. The custom fields are correctly declared and
populated. However, the developer receives complaints that the component
performs slowly.
What can the developer do to improve the performance?
The Account object has a field, Audit_Code_c, that is used to specify what type of auditing the Account needs and a Lookup to User, zudizar_c, that is the assigned auditor. When an Account is initially created, the user specifies the Audit_Code c. Each User in the org has a unique text field, Audit_Code _e, that is used to automatically assign the correct user to the Account’s Auditor_c field.
What should be changed to most optimize the code’s efficiency?
Choose 2 answers
A developer is creating a Lightning web component to display a calendar. The component will be used in multiple countries. In some locales, the first day of the week is a Monday, or a Saturday, or a Sunday. ‘What should the developer do to ensure the calendar displays accurately for users in every locale?
A developer is asked to develop a new AppFxchange application. A feature of the program creates Survey records when a Case reaches a certain stage and is of a certain Record Type. This feature needs to be configurable, as different Salesforce instances require Surveys at different times. Additionally, the out-of-the-box AppExchange app needs to come with a set of best practice settings that apply to
most customers.
What should the developer use to store and package the custom configuration settings for the app?
An Apex trigger and Apex class increment a counter, Edit __C, any time the Case is changed.
A)
B)
C)
D)