A developer has a Apex controller for a Visualforce page that takes an ID as a URL parameter. How should the developer prevent a cross site scripting vulnerability?
A. ApexPages.currentPage() .getParameters() .get('url_param')
B. ApexPages.currentPage() .getParameters() .get('url_param') .escapeHtml4()
C. String.ValueOf(ApexPages.currentPage() .getParameters() .get('url_param'))
D. String.escapeSingleQuotes(ApexPages.currentPage() .getParameters(). get('url_param'))
A Next Best Action strategy uses an Enchance 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 static ListRecommendation getLevel(List
B. @InvocableMethod global static List> getLevel(List
C. @InvocableMethod global List> getLevel(List
D. @InvocableMethod global Recommendation getLevel (ContactWrapper input) { /*implementation*/ }
What is the order of operations when a record is saved in Salesforce?
A. Process flows, triggers, workflow, commit
B. Workflow, process flows, triggers, commit
C. Workflow, triggers, process flows, commit
D. Triggers, workflow, process flows, commit
Which statement generates a list of Leads and Contacts that have a field with the phrase 'ACME'?
A. List
B. List> searchList = (FIND "*ACME*" IN ALL FIELDS RETURNING Contact, Lead);
C. Map
D. List> searchList = (SELECT Name, ID FROM Contact, Lead WHERE Name like '%ACME%');
A developer needs to import customer subscription records into salesforce and attach them to existing account records. Which 2 actions should the developer take to ensure the subscription records are related to the correct account records? Choose 2 answers
A. Match an external ID text field to a column in the imported file
B. Match an auto-number field to a column in the imported file
C. Match the name field to a column in the imported file
D. Match the id field to a column in the imported file
What is the return data type when ApexPages.currentPage().getParameters() is used to retrieve URL parameters from a visualforce controller?
A. Map
B. List
C. Enum
D. String[]
When the value of a field of an account record is updated, which method will update the value of a custom field opportunity? Choose 2 answers.
A. A process builder on the Account object
B. An Apex trigger on the Account object.
C. A cross-object formula field on the Account object
D. A workflow rule on the Account object
The Sales Management team hires a new intern. The intern is not allowed to view Opportunities, but needs to see the Most Recent Closed Date of all child Opportunities when viewing an Account record. What would a developer do to meet this requirement?
A. Create a trigger on the Account object that queries the Close Date of the most recent Opportunities.
B. Create a Workflow rule on the Opportunity object that updates a field on the parent Account.
C. Create a formula field on the Account object that performs a MAX on the Opportunity Close Date field.
D. Create a roll-up summary field on the Account object that performs a MAX on the Opportunity Close Date field.
What is an accurate statement about variable scope? (Choose 3)
A. Parallel blocks can use the same variable name.
B. A variable can be defined at any point in a block.
C. Sub-blocks cannot reuse a parent block's variable name.
D. Sub-blocks can reuse a parent block's variable name if it's value is null.
E. A static variable can restrict the scope to the current block of its value is null.
When can a developer use a custom Visualforce page in a Force.com application? (Choose 2)
A. To generate a PDF document with application data
B. To create components for dashboards and layouts
C. To deploy components between two organizations
D. To modify the page layout settings for a custom object
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?
A. Option A
B. Option B
C. Option C
D. Option D
Which three resources in an Azure Component can contain JavaScript functions?
A. Controllers
B. helper
C. Design
D. Style
E. Renderer
Which two types of process automation can be used to calculate the shipping cost for an Order when the Order is placed and apply a percentage of the shipping cost of some of the related Order Products? Choose 2 answers
A. Workflow Rule
B. Approval Process
C. Process Builder
D. Flow Builder
A developer created a new trigger that inserts a Task when a new Lead is created. After deploying to production, an outside integration that reads task records is periodically reporting errors. Which change should the developer make to ensure the integration is not affected with minimal impact to business logic?
A. Deactivate the trigger before the integration runs.
B. Use a try-catch block after the insert statement.
C. Use the Database method with allOrNone set to false.
D. Remove the Apex class from the integration user's profile.
Which two sfdx commands can be used to add testing data to a Developer sandbox?
A. Forced: data:bulk:upsert
B. Forced: data: object :upsert
C. Forced: data: tree: upsert
D. Forced: data:async:upsert