option

RS-Certification

COMMENTS STADISTICS RECORDS
TAKE THE TEST
Title of test:
RS-Certification

Description:
RS-Certification

Author:
Harry saraf
(Other tests from this author)

Creation Date:
27/03/2021

Category:
Personal

Number of questions: 246
Share the Test:
Facebook
Twitter
Whatsapp
TAKE THE TEST
Last comments
No comments about this test.
Content:
Which type of controller should a developer use to include a list of related records for a custom object record on a visualforce page without needing additional test coverage? List Controller Controller Extension Standard Controller Custom Controller.
Which is a valid apex assignment? Double x = 5 Integer x=5 * 1.0 Integer = 5.0 Float x = 5.0.
A developer has the following class and trigger code public class InsuranceRates { public static final decimal smokerCharge = 0.01; } trigger ContactTrigger on Contact (before insert) { InsuranceRates rates = new InsuranceRates(); decimal basecost = xxx; } Which code segment should a developer insert at the xxx to set the base cost variable to the value of the class variable smokercharge? ContacttTigger.InsuranceRates.smokerCharge InsuranceRates.smokerCharge rates.smokerCharge rates.getSmokerCharge().
A developer runs the following anonymous code block: List<Account> acc = [select id from Account limit 10]; delete acc; Database.emptyRecycleBin(acc); System.debug(Limits.getDMLStatements() + ‘, ’ + Limits.getLimitDMLStatements()) What is the result? 2, 150 150, 2.
In order to override a standard action with a visualforce page, which attribute must be defined in the <apex:page> tag? PageReference Controller Override StandardController.
A developer is creating an enhancement to an application that will allow people to be related to their employer. Which data model provides the simplest solution to meet the requirements? Create a junction object to relate many people to many through master-detail relationship Create a junction object to relate many people to many through lookup relationship Create a lookup relationship to indicate that a person has an employer Create a master-detail relationship to indicate that a person has an employer.
A developer working on a time management application wants to make total hours for each timecard available to application users. A timecard entry has a master-detail relationship to a timecard. Which approach should the developer use to accomplish this declaratively? A visualforce page that calculates the total number of hours for a timecard and displays it on the page A roll-up summary field on the timecard object that calculates the total hours from timecard entries for that timecard An apex trigger that uses an aggregate query to calculate the hours for a given time card and stores it in a custom field A process builder process that updates a field on the timecard when a timecard entry is created.
Which control statement should a developer use to ensure that a loop body executes at least once? do { } while (cond) for (init_stmt; exit_cond;increment) { } while (condition) { } for (variable : list_or_set) { }.
A developer has javascript code that needs to be called by controller functions in multiple components by extending a new abstract component. Which resource in the abstract component bundle allows the developer to achieve this? Rendered.js Superrender.js Controller.js Helper.js.
Which two conditions cause workflow rules to fire? Choose two answer - An Apex batch process that changes field values Converting leads to person account Updating record using bulk API Changing territory assignments of accounts and opportunities.
How many level of child records can be returned in a single SOQL query from one parent object? 5 7 3 1.
A platform developer needs to implement a declarative solution that will display the most recent closed won date for all opportunity records associated with an account. Which field is required to achieve this declaratively? Roll-up summary field on the account object Cross-object formula field on the opportunity object Cross-object formula field on the account object Roll-up summary field on the opportunity object.
Which option should a developer use to create 500 accounts and make sure that duplicates are not created for existing account sites? Sandbox template Salesforce-To-Salesforce Data Loader Data Import Wizard.
Which declarative process automation feature supports iterating over multiple records? Validation rules Flows Workflow rules Approval process.
For which example task should a developer use a trigger rather than a workflow rule? To send an email to a hiring manager when a candidate accepts a job offer To set the primary Contact on an Account record when it is saved To set the name field of an expense report record to expense and the date when it is saved To notify an external system that a record has been modified.
Which two components are available to deploy using the metadata api? Choose 2 answers Lead conversion settings Web-to-Lead Case settings Web-to-Case.
A developer created a visualforce page using a custom controller that calls an apex helper class. A method in the helper class hits a governor limit. What is the result of the transaction? All changes made by the custom controller are saved The helper class creates a savepoint and continues The custom controller calls the helper class method again All changes in the transaction are rolled back.
Which Salesforce feature allows a developer to see when a user logged in to Salesforce if real-time notification is not required? Calendar Events Asynchronous Data Capture Events Event Monitoring Log Developer Log.
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? The transaction will fail due to exceeding the governor limit. The try/catch block will handle any DML exceptions thrown. The try/catch block will handle exceptions thrown by the governor limit. The transaction will succeed and changes will be committed.
Which process automation should be used to send an outbound message without using Apex code? Approval Process Process builder Workflow Rule Flow Builder.
A developer has an Apex controller for a Visualforce page that takes an ID as a URL parameter. How should the developer prevent a cross-site scripting vulnerability? Apexpage.currentPage().getParameters.get(‘url_param’); String.escapeSingleQuotes(ApexPages.currentPage().getParameters().get(‘url_para m’)) Apexpage.currentPage().getParameters.get(‘url_param’).escapeHtml4() String.valueOf(ApexPages.currentPage().getParameters().get(‘url_param’)).
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 2 answers Create a Visualforce page that performs the HTTP REST callout, and use a Visualforce quick action to expose component on the Opportunity detail page. Create a Lightning component that performs the HTTP REST callout, and use a Lightning Action to expose component on the Opportunity detail page 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. Create an after update trigger on the Opportunity object that calls a helper method using @Future(Callout=true) to perform the HTTP REST callout.
A development team wants to use a deployment script to automatically deploy to a sandbox during their development cycles. Which should they use to deploy to the sandbox? Change Sets VSCode Developer Console Ant Migration Tool.
Which three data types can a SOQL query return? Choose 3 answers Integer Long List of sObject sObject.
Which code in a Visualforce page and /or controller might present a security vulnerability? <apex:outputField value=”{!ctrl.userInput}”/> <apex:outputText escape=”false” value=”(!$CurrentPage.parameters.UserInput)” /> <apex:outputField escape=”false” value=”{!ctrl.userInput}”/> <apex:outputText value=”(!$CurrentPage.parameters.UserInput)” />.
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? Use Test. getStandardPricebookId() to get the standard price book ID A B C.
Universal Containers (UC) decided it will not send emails to support personnel directly from Salesforce in the event that an unhandled exception occurs. Instead, UC wants an external system to be notified of the error. What is the appropriate publish/subscribe logic to meet these requirements? Have the external system subscribe to the BatchApexError event, no publishing is necessary. Publish the error event using the addError() method and write a trigger to subscribe to the event and notify the external systems. Publish the error event using the addError() method and have the external system subscribe to the event using the CometD Publish the error event using the Eventbus.publish() method and have the external system subscribe to the event using the CometD.
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? Run the tests using “Run All Tests” method. Remove the falling test methods from the test class. Create a test class and methods to cover the Apex trigger. Increase the test class coverage on the helper class.
What are three ways for a developer to execute tests in an org? Choose 3 answers Bulk API Tooling API Setup Menu Metadata API SalesforceDX.
A recursive transaction is initiated by a DML statement creating records for these two objects: 1. Accounts 2. Contacts The Account trigger hits a stack depth of 16. Which statement is true regarding the outcome of the transaction? The transaction succeeds as long as the contact trigger stack depth is less than 16. The transaction succeeds and all changes are committed to the database. The transaction fails and all the changes are rolled back. The transaction fails only if the contact trigger stack depth is greater or equal to 16.
Given the following trigger implementation: trigger leadTrigger on Lead (before update){ final ID BUSINESS_RECORDTYPEID = ‘01250000009Qad’; for(Lead thisLead : Trigger.new){ if(thisLead.Company !=null && thisLead.RecordTypeId != BUSINESS_RECORDTYPEID){ thisLead.RecordTypeId = BUSINESS_RECORDTYPEID; } } } The developer receives deployment errors every time a deployment is attempted from sandbox to production. What should a developer do to ensure a successful deployment? Ensure BUSINESS_RECORDTYPEID is published as part of the deployment components 2-Ensure BUSINESS_RECORDTYPEID is published as part of the deployment components 3-Ensure BUSINESS_RECORDTYPEID is published as part of the deployment components 4-Ensure BUSINESS_RECORDTYPEID is published as part of the deployment components.
Ensure BUSINESS_RECORDTYPEID is published as part of the deployment components Data Loader runs from the developer’s browser. Data Import Wizard does not support Opportunities. Data Loader automatically relates Opportunities to Accounts. Data Import Wizard cannot import all 500 records.
A developer wrote Apex Code that calls out to an external system.How should a developer write the test to provide test coverage? Write a class that extends HTTPCalloutMock. Write a class that implements the HTTPCalloutMock Interface. Write a class that implements the WebserviceMock Interface. Write a class that extends WebserviceMock.
A developer is debugging the following code to determine why accounts are not being created. Account a = new Account(Name =’A’); Database.insert(a, false); How should the code be altered to help debug the issue? Add a system.debug() statement befire the insert method. Add a try/catch around the insert method. Set the second insert method parameter to TRUE. Collect the insert method return value in a SaveResult record.
Universal Containers store orders and lime items in salesforce. For security reasons, financial representatives are allowed to see information on the Order such as order amount, but they are not to see the Line Items on the order. Which type of relationship should be used? Lookup Direct Lookup Indirect Lookup Master-Details.
A developer must modify the following code snippet to prevent the number of SOQL queries issues from exceeding the platform governor limit. Public class without sharing OpportunityService{ Public static List<OpportunityLineItem> getOppprtunityProducts(Set<Id> opportunityIds){ List<OpportunityLineItem> oppLineItems = new List<OpportunityLineItem>(); for(Id thisOppId : opportunityIds){ oppLineItems.addAll([Select Id FROM OpportunityLineItem WHERE OpportunityID = :thisOppId]); } Return OppLineItems; } } The above method be called during a trigger execution via a Lightning component. Which technique should be implemented to avoid reaching the governor limit? Use the System.Limits.getQueries() method to ensure the number of queries is less than 100. Use the System.Limits.getQueries() method to ensure the number of queries is less than 100. Refactor the code above to perform the SOQL query only if the set of opportunityIDs contains less than 100. Refactor the code above to perform only one SOQL query, filtering by the Set of opportunityIds.
A lighting component has a wired property, searchResults, that stores a list of opportunities. Which definition of the Apex method, to which the searchResults property is wired, should be used? @AuraEnabled(cacheable=true) Public static List<Opportunity> search(String terms){/*implementation*/} @AuraEnabled(cacheable=true) Public List<Opportunity> search(String terms){/*implementation*/} @AuraEnabled(cacheable=false) Public static List<Opportunity> search(String terms){/*implementation*/} @AuraEnabled(cacheable=false) Public List<Opportunity> search(String terms){/*implementation*/}.
A developer must create a lightning component that allows users to input Contact record information to create a Contact record, including a Salary__ 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? <lightning-input-field field-name=”Salary__c”> </lightning-input-field field> <lightning-formatted-number value=”Salary__c” format-style=”currency”> </lightning-formatted-number > <lightning-input type=”number” value=”Salary__c” formatter=”currency”> </lightning-input> <lightning-input-currency value=”Salary__c”> </lightning-input-currency >.
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? class myClass{ class CustomException extends QueryException{} public static Account aQuery(){ Account the Account; 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; } } Querying Accounts. Query Exception. Done. Querying Accounts. Custom Exception. Done. Querying Accounts. Query Exception. Querying Accounts. Custom Exception.
What should be enabled for working of Scratch org? Developer hub (Dev Hub) 1-Developer hub (Dev Hub).
What are the three languages used in the visualforce page? Javascript HTML CSS JAVA PHP.
Which three code lines are required to create a Lightning component on a Visualforce page? Choose 3 answers $Lightning.createComponent <apex:slds/> $Lightning.useComponent $Lightning.use <apex:includeLightning/>.
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. List<Contact> performSearch(String lastname){ Return Database.query(SELECT Id, FirstName, LastName FROM Contact WHERE LastName like % ’ + LastName + ‘ % ‘ ) ; } What are two ways the developer can update the method to prevent a SOQL injection attack? Choose 2 answers Use variable binding and replace the dynamic query with a static SOQL. Use a regular expression on the parameter to remove special characters. Use the escapeSingleQuotes method to sanitize the parameter before its use. Use the @ReadOnly annotation and the with sharing keyword on the class.
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? The variable , myAccount, is automatically cast to the List data type. The first Account returned is assigned to my Account. An unhandled exception is thrown and code terminates. The query fails and an error is written to the debug log.
Which three statements are true regarding custom exceptions in Apex? Choose 3 answers A custom exception class must extend the system Exception class. A custom exception class can implement one or many interfaces. A custom exception class cannot contain member variables or methods. A custom exception class name must end with "Exception". A custom exception class can extend other classes besides the Exception class.
The values “High”, “Medium”, and “Low” are identified as common values for multiple picklists across different objects. What is an approach a developer can take to streamline maintenance of the picklists and their values, while also restricting the values to the ones mentioned above? Create the picklist on each object as a required field and select “Display values alphabetically, not in the order entered” Create the picklist on each object and use a Global Picklist Value Set containing the values. Create the picklist on each object and select “Restrict picklist to the values defined in the value set”. Create the picklist on each object and add a validation rule to ensure data integrity.
What is a correct pattern to follow when programming in Apex on a multitenant platform? USE THE WITH SHARING KEYWORD WHEN DECLARING AN APEX CLASS TO PREVENT ACCESS FROM OTHER SERVER TENANTS USE QUERIES TO SELECT THE FEWEST FIELDS AND RECORDS POSSIBLE TO AVOID EXCEEDING GOVERNOR LIMITS. CREATE APEX CODE IN A SEPARATE ENVIRONMENT FROM THE SCHEMA TO REDUCE DEPLOYMENT ERRORS. RUN DATA MANIPULATION LANGUAGE (DML) ON ONE RECORD AT A TIME TO AVOID POSSIBLE DATA CONCURRENCY ISSUES.
Which two types of code represent the controller in model-view-controller (MVC) architecture on the Lightning Platform? (Select two answers.) STANDARDCONTROLLER SYSTEM METHODS THAT ARE REFERENCED BY VISUALFORCE JAVASCRIPT THAT IS USED TO MAKE A MENU ITEM DISPLAY ITSELF A STATIC RESOURCE THAT CONTAINS CASCADING STYLE SHEETS (CSS) AND IMAGES CUSTOM APEX AND JAVASCRIPT CODE THAT IS USED TO MANIPULATE DATA.
What should a developer do to update a picklist field on related opportunity records when a modification to the associated account record is detected? CREATE A WORKFLOW RULE WITH A FIELD UPDATE. CREATE A VISUALFORCE PAGE. CREATE A LIGHTNING COMPONENT. CREATE A PROCESS WITH PROCESS BUILDER.
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? Number with External ID Lookup Direct Lookup Indirect Lookup.
A developer writes a single trigger on the Account object on the after insert and after update events. A workflow rule modifies a field every time an Account is created or updated.How many times will the trigger fire if a new Account is inserted, assuming no other automation logic is implemented on the Account? 8 2 4 1.
Universal Containers wants a list button to display a visualforce page that allow users to edit multiple records.What Visualforce feature supports this requirement? <apex:listButton> tag Custom controller recordSetVar page attribute controller extension .
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 injections? Choose 2 answers String query = ‘SELECT Id FROM Account WHERE Name LIKE \ ’%’ + String.escapeSingleQuotes(name) + ‘%’’ List<Account> results = Database.query(query); String query = ‘%’ + name + ‘%’ ; List<Account> results = [SELECT Id FROM Account WHERE Name LIKE ‘query’;.
What are three ways for a developer to execute tests in an org? Choose 2 answers Developer console Tooling api Metadata api Bulk api.
Universal Containers has as large number of custom applications that were built using a third-party JavaScript framework and exposed using Visualforce pages. The company wants to update these applications to apply styling that resembles the look and feel of Lightning Experience. What should the developer do to fulfil the business request in the quickest and most effective manner? Set the attribute enableLightning to true in the definition Enable Available for Lightning Experience, Lightning Communities, and the mobile app on Visualforce pages used by the custom application Incorporate the Salesforce Lightning Design System CSS stylesheet into the JavaScript applications Rewrite all Visualforce pages as Lightning components.
What is a fundamental difference b/w Master-Detail relationship and Lookuprelationship? A Master-Detail relationship detail record inherits the sharing and security of its master record. 1-A Master-Detail relationship detail record inherits the sharing and security of its master record.
What would a developer use to ensure that a user populates the Lead Source field prior to converting a Lead? The sales management team requires that the Lead Source field of the Lead record be populated when a Lead is converted Process builder Validation rule Formula field Workflow rule.
Which two are best practices when it comes to component and application event handling? (Choose two.) Reuse the event logic in a component bundle, by putting the logic in the helper. Use component events to communicate actions that should be handled at the application level. Handle low-level events in the event handler and re-fire them as higher-level events. Try to use application events as opposed to component events.
A developer must create a ShippingCalculator class that cannot be instantiated and must include a working default implementation of a calculate method, that sub-classes can override. What is the correct implementation of the ShippingCalculator class? Public abstract class ShippingCalculator {public override calculate() { /implementation/ }} Public abstract class ShippingCalculator {public abstract calculate() { /implementation/ }} Public abstract class ShippingCalculator {public void calculate() { /implementation/ }} Public abstract class ShippingCalculator {public virtual void calculate() { /implementation/ }}.
How can a developer checks the test coverage of active process builder and flows before deploying them in a change set Use the apex testresult class Use soql and tooling api Use the flow properties page Use the code coverage setup page.
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? Choose 2 answers Use the static keyword and assign its value in the class constructor. Use the final keyword and assign its value in the class constructor. Use the static keyword and assign its value in a static initializer. Use the final keyword and assign its value when declaring the variable.
how does the lightning component framework help developers implement solutions faster ? By providing an Agile process with default steps By providing change history and version control By providing device awareness for mobile and desktops By providing code review standards and processes.
Which action cause a before trigger to fire by default for account Importing data using data loader and the bulk api Updating address using the mass address update tool Converting leads to person accounts Renaming or replacing picklists.
Which process automation should be used to send an outbound message without using Apex code? Approval Process Process builder Workflow Rule Flow Builder.
A developer wants to mark each account in a List<Accounts> as either Active or Inactive based on the Last ….. Being more than 90 days. Which apex technique should the developer use? An if/else statement, with for loop inside A for loop, with a switch statement inside A switch statement, with a for loop inside A for loop, with an if/else statement inside.
A developer has a visualforce page and custom controller to save Account records. The developer wants to display violations to the user. How can the developer make sure that validation rule violations are displayed? Use a try/catch with a custom exception class. Add a custom controller attribute to display the message. Perform the DML using the Database.upsert() method Include <apex:messages> on the visualforce page.
Which action causes a before trigger to fire by default for accounts? Importing data using the Data Loader and the Bulk API Converting Leads to person accounts Renaming or replacing picklists Updating addresses using the mass address update tool.
Which two statements accurately represent the mvc framework implementation is salesforce? (Choose 2 answer) Standard and custom object used in the app schema represent the View (V) part of the MVC framework Lightning component HTML files represent the Model (M) part of the MVC framework Trigger used to create records represent the model (M) part of the MVC framework Validation rules enforce business rules and represent the controller © part of MVC framework.
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? Public class CheckPaymentProcessor implements PaymentProcessor { Public void pay(Decimal amount) {} } Public class CheckPaymentProcessor implements PaymentProcessor { Public void pay(Decimal amount) ; } Public class CheckPaymentProcessor extends PaymentProcessor { Public void pay(Decimal amount) { } } Public class CheckPaymentProcessor extends PaymentProcessor { Public void pay(Decimal amount) ; }.
What is the result of the following code snippet? Public void doWork(Account acct){ for( Integer i=0;i<=200;i++){ Insert acct; } } 201 Accounts are inserted 1 Account is inserted 200 Accounts are inserted 0 Accounts are inserted.
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. List<Contact> performSearch(String lastname){ Return Database.query(SELECT Id, FirstName, LastName FROM Contact WHERE LastName like % ’ + LastName + ‘ % ‘ ) ; } What are two ways the developer can update the method to prevent a SOQL injection attack? Choose 2 answers Use variable binding and replace the dynamic query with a static SOQL. Use a regular expression on the parameter to remove special characters. Use the escapeSingleQuotes method to sanitize the parameter before its use. Use the @ReadOnly annotation and the with sharing keyword on the class.
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 deployment? Scratch Orgs Full Copy Sandboxes Developer Sandboxes Developer Orgs.
A developer must troubleshoot to pinpoint the causes of performance issues when a custom page loads in the org. Which tool should the developer use to troubleshoot? Developer Console Visual Studio Code IDE Salesforce CLI AppExchange.
Which three operations affect the number of times a trigger can fire? Choose 3 answers Workflow Rules Process Flows Roll-up Summary fields Approval Flow.
Which exception type cannot be caught? NoAccessException LimitException A Custom Exception CalloutException.
A developer needs to confirm that a Contact trigger works correctly without changing the organizations data. What should the developer do to test the Contact trigger? Use the New button on the Salesforce Contacts Tab to create a new Contact record. Use the Open Execute Anonymous feature on the Developer Console to run an “insert Contact” Apex Class. Use the Test menu on the Developer Console to run all test classes for the Contact trigger Use Deploy from the VSCode IDE to deploy an “insert Contact” Apex Class.
A developer wants to retrieve the Contact and Users with the email address ‘dev@uc.com’. Which SOSL statement should the developer use? FIND {Email = ‘dev@uc.com’} IN Contact, User FIND {Email = ‘dev@uc.com’} RETURNING Contact(Email), User(Email) FIND Email IN Contact, User for {dev@uc.com} FIND (dev@uc.com) IN Email Fields RETURNING Contact (Email), User (Email).
Which three steps allow a custom SVG to be included in a Lightning web component? Choose 3 answers Upload the SVG as a static resource. Reference the getter in the HTML template. Import the SVG as a content asset file. Import the static resource and provide a getter for it in JavaScript. Reference the import in the HTML template.
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? Use Test.loadData() and reference a csv file. Use Test.loadData() and reference a static resource. Use SOQL to query the org for the required data. Use anonymous apex to create the required data.
Universal Containers (UC) uses a custom object called Vendor. The Vendor custom object has a Master-Detail relationship with the standard Account object. Based on some internal discussions, the UC administrator tried to change the Master-Detail relationship to a Lookup relationship but was not able to do so. What is a possible reason that this change was not permitted? The Vendor records have existing values in the account object. The Account object is included in a workflow on the vendor object. The Vendor object must use a master-detail field for reporting. The Account records contain Vendor Roll-Up Summary fields.
Which three process automations can immediately send an email notification to the owner of an Opportunity when its amount is changed to be greater than $10,000? Choose 3 answers Process Builder Escalation Rule Flow Builder Approval Process Workflow Rule.
A developer has to identify a method in an Apex class that performs resource intensive actions in memory by iterating over the result set of a SOQL statement on the Account. The method also performs a DML statement to save the changes to the database. Which two techniques should the developer implement as a best practice to ensure transaction control and avoid exceeding governor limits? Choose 2 answers Use the System.Limit class to monitor the current CPU governor limit consumption. Use the @ReadOnly annotation to bypass the number of rows returned by a SOQL. Use the Database.Savepoint method to enforce database integrity. Use Partial DML statements to ensure only valid data is committed.
Which statement generates a list of Leads and Contacts that have a field with the phrase ‘ACME’? List<sObject> searchList = (FIND “*ACME*” IN ALL FIELDS RETURNING Contact, Lead); Map<sObject> searchList = (FIND “*ACME*” IN ALL FIELDS RETURNING Contact, Lead); List<List <sObject>> searchList = (select Name, Id from Contact, Lead where Name like ‘%ACME%’); List<List <sObject>> searchList = (FIND “*ACME*” IN ALL FIELDS RETURNING Contact, Lead);.
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? Line Item has a lookup field to Order and there can be many line items per order. Order has a lookup field to Line Item and there can be many line items per order. Order has a Master-Detail field to Line item and there can be many line items per order. Line Item has a Master-Detail field to Order and the Master can be re-parented.
A developer needs to create a custom interface in Apex. Which three considerations must the developer keep in mind while developing the Apex interface? New methods can be added to a public interface within a released package. The Apex class access modifier can be set to private, public, or global. A method defines in an Apex interface cannot have an access modifier. A method implementation can be defined within Apex interface. The Apex class must be declared using the Interface keyword.
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? [SELECT Id, (SELECT Id FROM Job_Applications_r) FROM Contact WHERE Account.Industry = ‘Technology’]; [SELECT Id, (SELECT Id FROM Job_Applications_r) FROM Contact WHERE Accounts.Industry = ‘Technology’]; [SELECT Id, (SELECT Id FROM Job_Applications_c) FROM Contact WHERE Accounts.Industry = ‘Technology’]; [SELECT Id, (SELECT Id FROM Job_Application_c) FROM Contact WHERE Account.Industry = ‘Technology’];.
Which code displays the contents of a Visualforce page as a PDF? <apex:page contentType="application/pdf"> <apex:page renderAs="pdf"> <apex:page renderAs="application/pdf"> <apex:page contentType="pdf".
A developer writes a single trigger on the Account object on the after insert and after update events. A workflow rule modifies a field every time an Account is created or updated. 8 1 4 2.
A developer is asked to create a Visualforce page that displays some Account fields as well as fields configured on the page layout for related Contacts. Use the <apex:include> tag. Use the <apex:relatedList> tag. Add a method to the standard controller. Create a controller extension.
What does the Lightning Component framework provide to developers? Support for Classic and Lightning UIs Templates to create custom components Extended governor limits for applications Prebuilt components that can be reused.
A Visual Flow uses an Apex Action to provide additional information about multiple Contacts, stored in a custom class, ContactInfo. @InvocableMethod(label=’Additional Info’) public ContactInfo getInfo(Id contactId) { /*implementation*/ } @InvocableMethod(label=’Additional Info’) public List<ContactInfo> getInfo(List<Id> contactIds) { /*implementation*/ } @InvocableMethod(label=’Additional Info’) public static ContactInfo getInfo(Id contactId) { /*implementation*/ } @InvocableMethod(label=’Additional Info’) public static List<ContactInfo> getInfo(List<Id> contactIds) { /*implementation*/ }.
Where are two locations a developer can look to find information about the status of asynchronous or future calls? Time-Based Workflow Monitor Apex Flex Queue Apex Jobs Paused Flow Interviews component.
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? Increase the test class coverage on the helper class. Remove the failing test methods from the test class. Run the tests using the ‘Run All Tests’ method. Create a test class and methods to cover the Apex trigger.
A developer must build an application that tracks which Accounts have purchased specific pieces of equipment that are represented as Products. Each Account could purchase many pieces of equipment. How should the developer track that an Account has purchased a piece of equipment? Use the Asset object. Use a Master-Detail on Product to Account Use a Custom object Use a Lookup on Account to Product.
A developer has a requirement to create an Order when an Opportunity reaches a ‘Closed-Won’ status. Which tool should be used to implement this requirement? Lightning Component Apex Trigger Lightning Flow Process Builder.
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? Developer orgs Developer sandboxes Full Copy sandboxes Scratch orgs.
Universal Containers (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 add to create the most efficient model that supports the business need? Add a Master-Detail field on the Global Address object to the Account object. Add a Master-Detail field on the Account object to the Global Address object. Add a Lookup field on the Global Address object to the Account object. Add a Lookup field on the Account object to the Global Address object.
Which code should be used to update an existing Visualforce page that uses standard Visualforce components so that the page matches the look and feel of Lightning Experience? <apex:styleSheet value="({$URLFOR($Resource.slds,’assets/slds.css’)}"> <apex:slds/> <apex:page lightningStyleSheets="true"> <apex:includeLightning/>.
An org tracks customer orders on an Order object and the line items of an Order on the Line Item object. The Line Item object has a Master/Detail relationship to the Order object. A developer has a requirement to calculate the order amount on an Order and the line amount on each Line Item based on quantity and price. What is the correct implementation? Write a single before trigger on the Line Item that calculates the item amount and updates the order amount on the Order. Write a process on the Line Item that calculates the item amount and order amount and updates the fields on the Line Item and the Order. Implement the line amount as a numeric formula field and the order amount as a roll-up summary field. Implement the line amount as a currency field and the order amount as a SUM formula field.
Which two events need to happen when deploying to a production org? (Choose two.) All Process Builder Processes must have at least 1% test coverage. All Apex code must have at least 75% test coverage. All triggers must have at least 1% test coverage. All Visual Flows must have at least 1% test coverage.
A developer uses a loop to check each Contact in a list. When a Contact with the Title of ‘Boss’ is found, the Apex method should jump to the first line of code outside of the for loop. Which Apex solution will let the developer implement this requirement? return; continue; break; System.assert(false);.
Universal Containers uses a simple Order Management app. On the Order Lines, the order line total is calculated by multiplying the item price with the quantity ordered. There is a Master-Detail relationship between the Order and the Order Lines object. What is the best practice to get the sum of all order line totals on the order header? Declarative Roll-Up Summaries App Roll-Up Summary field Process Builder Apex Trigger.
Which two are phases in the Salesforce Application Event propagation framework? (Choose two.) Bubble Default Control Emit.
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? Order has a Lookup field to Line Item and there can be many Line Items per Order. Line Item has a Lookup field to Order and there can be many Line Items per Order. Order has a Master-Detail field to Line Item and there can be many Line Items per Order. Line Item has a Master-Detail field to Order and the Master can be re-parented.
The sales management team at Universal Containers requires that the Lead Source field of the Lead record be populated when a Lead is converted. What should be used to ensure that a user populates the Lead Source field prior to converting a Lead? Workflow Rule Validation Rule Formula Field Process Builder.
What should be used to create scratch orgs? Sandbox refresh Salesforce CLI Developer Console Workbench.
Which two are best practices when it comes to component and application event handling? Handle low-level events in the event handler and re-fire them as higher-level events. Try to use application events as opposed to component events. Use component events to communicate actions that should be handled at the application level. Reuse the event logic in a component bundle, by putting the logic in the helper.
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. How should a developer implement this feature? Build an Account Assignment Rule. Build an Account custome Trigger. Build an Account Approval Process. Build an Account Workflow Rule.
Which two operations can be performed using a formula field? Displaying the last four digits of an encrypted Social Security number. Triggering a Process Builder. Displaying an Image based on the Opportunity Amount. Calculating a score on a lead based on the information from another field.
Which three process automations can immediately send an email notification to the owner of an Opportunity when its Amount is changed to be greater than $10,000? Workflow Rule Flow Builder Approval Process Escalation Rule Process Builder.
List aList = [SELECT ID FROM Account LIMIT 5]; for (Account a : aList){ List cList = [SELECT ID FROM Contact WHERE AccountID = :a.ID); } 5 6 1 2.
An Approval Process is defined in the Expensive_Item__c. A business rule dictates that whenever a user changes the Status to ‘Submitted’ on an Expense_Report__c record, all the Expense_Item__c records related to the expense report must must enter the approval process individually. Which approach should be used to ensure the business requirement is met? Create a Process Builder on Expense_Report__c with a “Submit for Approval” action type to submit all related Expense_Item__c records when the criteria is met. Create two Process Builders, one on Expense_Report__c to mark the related Expense_Item__c as submittable and the second on Expense_Item__c to submit the records for approval. Create a Process Builder on Expense_Report__c to mark the related Expense_Item__c as submittable and a trigger on Expense_item__c to submit the records for approval. Create a Process Builder on Expense_Report__c with an “Apex” action type to submit all related Expense_Item__c records when the criteria is met.
What are two ways a developer can get the status of an enqueued job for class that implements the queueable interface? View the Apex Status Page View the Apex Flex Queue View the Apex Jobs Page Query the AsyncApexJob object.
A developer must provide a custom user interface when users edit a Contact. Users must be able to use the interface in Salesforce Classic and Lightning Experience. What should the developer do to provide the custom user interface? Override the Contact’s Edit button with a Visualforce page in Salesforce Classic and a Lightning component in Lightning Experience. Override the Contact’s Edit button with a Visualforce page in Salesforce Classic and a Lightning page in Lightning Experience. Override the Contact’s Edit button with a Lightning component in Salesforce Classic and a Lightning component in Lightning Experience. Override the Contact’s Edit button with a Lightning page in Salesforce Classic and a Visualforce page in Lightning Experience.
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 most efficient way to ensure a value is selected every time a record is saved? Set “Use the first value in the list as the default value” as True. Set a validation rule to enforce a value is selected. Mark the field as Required on the field definition. Mark the field as Required on the object’s page layout.
Universal Containers (UC) uses a custom object called Vendor. The Vendor custom object has a Master-Detail relationship with the standard Account object. Based on some internal discussions, the UC administrator tried to change the Master-Detail relationship to a Lookup relationship but was not able to do so. What is a possible reason that this change was not permitted? The Account records contain Vendor roll-up summary fields. The Vendor object must use a Master-Detail field for reporting. The Vendor records have existing values in the Account object. The Account object is included on a workflow on the Vendor object.
A Licensed_Professional__c custom object exists in the system with two Master-Detail fields for the following objects: Certification__c and Contact. Users with the “Certification Representative” role can access the Certification records they own and view the related Licensed Professionals records, however users with the “Sales Representative” role report they cannot view any Licensed Professional records even though they own the associated Contact record. The organization’s sharing rules for Licensed_Professional__c have not finished their recalculation process. The organization recently modified the Sales Representative role to restrict Read/Write access to Licensed_Professional__c. The organization has a private sharing model for Certification__c, and Certification__c is the primary relationship in the Licensed_Professional__c object. The organization has a private sharing model for Certification__c, and Contact is the primary relationship in the Licensed_Professional__c object.
When using SalesforceDX, what does a developer need to enable to create and manage scratch orgs? Production Dev hub Environment Hub Sandbox.
A developer created this Apex trigger that calls MyClass.myStaticMethod: trigger myTrigger on Contact(before insert) { MyClass.myStaticMethode{trigger.new, trigger.oldMap); } 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? The deployment fails because the Apex trigger has no code coverage. The deployement fails because no assertions were made in the test method. The deployment passes because the Apex code has required (>75%) code coverage. The deployment passes because both classes and the trigger were included in the deployment.
What is the order of operations when a record is saved in Salesforce? process flows, triggers, workflow, commit workflow, process flows, triggers, commit workflow, triggers, process flows, commit triggers, workflow, process flows, commit.
for(Integer i = 0 ; i<500; i++){ Account a = new Account (Name='New Account' + i); insert a; } 150 0 500 100.
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? 2 1 3 4.
A developer writes a trigger on the Account object on the before update event that increments a count field. A workflow rule also increments the count field every time that an Account is created or updated. the field update in the workflow rule is configured to re-evaluate workflow rules. What is the value of the count field if an account is inserted with initial value 0, assuming no other automation logic is implemented on the Account? 3 2 1 4.
Application Events follow the traditional publish-subscribe model. Which method is used to fire an event? fire() emit() registerEvent() fireEvent().
How should a developer write unit tests for a private method in an Apex class? Use the SeeAllData annotation. Add a test method in the apex class. Use the TestVisible annotation. Mark the Apex class as global.
Publish the error event using the Eventbus.publish() method and have the external system subscribe to the event using CometD. The number of active Apex classes The number of records returned from database queries The number of methods in an Apex class The number of records processed in a loop.
If apex code executed inside the execute() method of an Apex class when implementing the Batchable interface, which two statement are true regarding governor limits? The Apex governor limits might be higher due to the asynchronous nature of the transaction. The Apex governor limits are reset for each iteration of the execute () method. The Apex governor limits are relaxed while calling the constructor of the Apex class. The Apex governor limits cannot be exceeded due to the asynchronous nature of the transaction.
A developer has a Visualforce page and custom controller to save Account records. The developer wants to display any validation rule violation to the user. How can the developer make sure that validation rule violations are displayed? Use a try/catch with a custom exception class. Perform the DML using the Database.upsert() method. Add custom controller attributes to display the message. Include <apex:message> on the Visualforce page.
developer created this Apex trigger that calls MyClass .myStaticMethod: trigger myTrigger on Contact(before insert) ( MyClass.myStaticMethod(trigger.new, trigger.oldMap); } 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 exist? The deployment passes because the Apex code has required (>75%) code coverage. The deployment passes because both classes and the trigger were included in the deployment. The deployment fails because no assertions were made in the test method. The deployment fails because the Apex trigger has no code coverage.
What is the correct definition of a Lightning Web component property that uses the getAccounts method @AuraEnabled(getAccounts, ‘$searchTerm’) accountList; @wire(getAccounts, ‘$searchTerm’) accountList; @AuraEnabled(getAccounts, {searchTerm: ‘$searchTerm’}) accountList; @wire(getAccounts, (searchTerm: ‘$searchTerm’)) accountList;.
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 two.) The Apex governor limits are reset for each iteration of the execute() method. The Apex governor limits cannot be exceeded due to the asynchronous nature of the transaction. The Apex governor limits might be higher due to the asynchronous nature of the transaction. The Apex governor limits are relaxed while calling the constructor of the Apex class.
Universal Containers implemented a private sharing model for the Account object. A Customer 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? Use the schema describe class to determine if the logged-in user has access to the account object. Use the without sharing keyword on the class declaration. Use the UserInfo Apex Class to filter all soql queries to returned records owned by the logged in user. Use the with sharing keyword on the class declaration.
Which Salesforce org has a complete duplicate copy of the production org including data and configuration? Developer Pro Sandbox Partial Copy Sandbox Production Full Sandbox.
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? Public class CreditCardPayment implements Payment {public override void makePayment(Decimal amount) { /*Implementation*/ } } Public class CreditCardPayment extends Payment {public virtual void makePayment(Decimal amount) { /*implementation*/ } } Public class CreditCardPayment implements Payment {public virtual void makePayment(Decimal amount) { /*implementation*/ } } Public class CreditcardPayment extends Payment {public override void makePayment(Decimal amount) { /*implementation*/ } }.
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? @StartTest @PreTest @TestSetup @isTest(SeeAllData=true).
Which aspect of Apex programming is limited due to multitenancy? The number of methods in an Apex class The number of records returned from database queries The number of active Apex classes The number of records processed in a loop.
A developer must create an Apex class, ContactController, that a Lightning component can use to search for Contact records. Users of the Lightning component should only be able to search for Contact records to which they have access. Which two will restrict the records correctly? (Choose two.) public class ContactController public with sharing class ContactController public without sharing class ContactController public inherited sharing class ContactController.
A developer observes that an Apex test method fails in the Sandbox. To identify the issue, the developer copies the code inside the test method and executes it via the Execute Anonymous tool in the Developer Console. The code then executes with no exceptions or errors. Why did the test method fail in the sandbox and pass in the Developer Console? The test method has a syntax error in the code. The test method does not use System.runAs to execute as a specific user. The test method is calling an @future method. The test method relies on existing data in the sandbox.
In terms of the MVC paradigm, what are two advantages of implementing the view layer of a Salesforce application using Aura Component-based development over Visualforce? (Choose two.) Self-contained and reusable units of an application Rich component ecosystem Server-side run-time debugging Automatic code generation.
What are two ways for a developer to execute tests in an org? Tooling API Developer Console Metadata API Bulk API.
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.) Unify the before insert and before update triggers and use Process Builder for the delete action.. Create helper classes to execute the appropriate logic when a record is saved. Maintain all three triggers on the Expense__c object, but move the Apex logic out of the trigger definition. Unify all three triggers in a single trigger on the Expense__c object that includes all events.
What is a fundamental difference between a Master-Detail relationship and a Lookup relationship? In a Master-Detail relationship, when a record of a master object is deleted, the detail records are not deleted.. In a Lookup relationship when the parent record is deleted, the child records are always deleted. A Master-Detail relationship detail record inherits the sharing and security of its master record. In a Lookup relationship, the field value is mandatory.
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? Declare the class and method using the public access modifier. Declare the class as global and use the public access modifier on the method. Declare the class as public and use the global access modifier on the method. Declare the class and method using the global access modifier.
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? Schema.sObjectType.Account.isDeletable() Account.isDeletable() accountRec.isDeletable() accountRec.sObjectType.isDeletable().
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? Data Loader runs from the developer’s browser. Data Loader automatically relates Opportunities to Accounts. Data Import Wizard does not support Opportunities. Data Import Wizard can not import all 500 records.
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? Declare maxAttempts as a private static variable on a helper class.. Declare maxAttempts as a variable on a helper class. Declare maxAttempts as a member variable on the trigger definition. Declare maxAttempts as a constant using the static and final keywords.
Which three statements are true regarding trace flags? (Choose three.) Setting trace flags automatically cause debug logs to be generated. Logging levels override trace flags. Trace flags override logging levels. If active trace flags are not set, Apex tests execute with default logging levels. Trace flags can be set in the Developer Console, Setup, or using the Tooling API.
A developer needs an Apex method that can process Account or Contact records. Which method signature should the developer use? public void doWork(Account | | Contact) public void doWork(Record theRecord) public void doWork(Account Contact) public void doWork(sObject theRecord).
A developer needs to update an unrelated object when a record gets saved. Which two trigger types should the developer create? (Choose two.) after insert before update before insert after update.
An after trigger on the Account object performs a DML update operation on all of the child Opportunities of an Account. There are no active triggers on the Opportunity object, yet a "maximum trigger depth exceeded" error occurs in certain situations. Which two reasons possibly explain the Account trigger firing recursively? (Choose two.) Changes to Opportunities are causing cross-object workflow field updates to be made on the Account. Changes to Opportunities are causing roll-up summary fields to update on the Account. Changes are being made to the Account during an unrelated parallel save operation. Changes are being made to the Account during Criteria Based Sharing evaluation.
Which statement is true about developing in a multi-tenant environment? Apex Sharing controls access to records from multiple tenants on the same instance. Org-level data security controls which users can see data from multiple tenants on the same instance. Governor limits prevent Apex from impacting the performance of multiple tenants on the same instance. Global Apex classes can be referenced from multiple tenants on the same instance.
What are three techniques that a developer can use to invoke an anonymous block of code? (Choose three.) Use the SOAP API to make a call to execute anonymous code. Create a Visualforce page that uses a controller class that is declared without sharing. Run code using the Anonymous Apex feature of the Developer’s IDE. Type code into the Developer Console and execute it directly. Create and execute a test method that does not specify a runAs() call.
An org has a data model with a Buyer__c object that has a lookup relationship to Region__c and a Supplier__c object has a lookup relationship to Region___c. How can a developer display data from the related Supplier__c records on a Visualforce page that has a standard controller for the Buyer__c object? Use rollup formula fields on the Buyer__c object to reference the related Supplier__c records through the Region__c.. Use SOQL in a controller extension to query for related Supplier__c records. Use a second standard controller for the Region__c object on a page to display the related Supplier__c records. Use merge field syntax to retrieve the Supplier__c records related to the Buyer__c record through the Region__c.
What can be used to delete components from production? A change set deployment with a destructiveChanges XML file. A change set deployment with the delete option checked An ant migration tool deployment with a destructiveChanges XML file and an empty package.xml file An ant migration tool deployment with a desctuctiveChanges XML file and the components to delete in the package.xml file.
A developer needs to save a List of existing Account records named myAccounts to the database, but the records do not contain Salesforce Id values. Only the value of a custom text field configured as an External ID with an API name of Foreign_Key__c is known. Which two statements enable the developer to save the records to the database without an Id? (Choose two.) Upsert myAccounts Foreign_Key__c; Upsert myAccounts(Foreign_Key__c); Database.upsert (myAccounts, Foreign_Key__c); Database.upsert(myAccounts).Foreign_Key__c;.
Which standard field is required when creating a new Contact record? LastName Name AccountId FirstName.
What is a benefit of using a trigger framework? Reduces trigger execution time Allows functional code to be tested by a test class Increases trigger governor limits Simplifies addition of context-specific logic.
A developer declared a class as follows. Public class wysiwyg{ // Properties and methods including DML. } An Apex trigger that invokes a helper method in this class A developer using the Developer Console that invokes a method in this class from the execute anonymous window A Visualforce page with an Apex controller that invokes a method in this class A user on an external system that has an API call into Salesforce that invokes a method in this class.
When a Task is created for a Contact, how can a developer prevent the task from being included on the Activity Timeline of the Contact’s Account record? In Activity Setting, uncheck Roll up activities to a contact’s primary account. Create a Task trigger to set the Account field to NULL. Use Process Builder to create a process to set the Task Account field to blank. By default, tasks do not display on the Account Activity Timeline.
Candidates are reviewed by four separate reviewers and their comments and scores which range from 1 (lowest) to 5 (highest) are stored on a review record that is a detail record for a candidate. What is the best way to indicate that a combined review score of 15 or better is required to recommend that the candidate come in for an interview? Use a Validation Rule on a total score field on the candidate record that prevents a recommended field from being true if the total score is less than 15. Use a Rollup Summary field to calculate the sum of the review scores, and store this in a total score field on the candidate. Use Visual Workflow to set a recommended field on the candidate whenever the cumulative review score is 15 or better. Use a Workflow Rule to calculate the sum of the review scores and send an email to the hiring manager when the total is 15 or better.
A developer must create a DrawList class that provides capabilities defined in the Sortable and Drawable interfaces. public interface Sortable { void sort(); } public interface Drawable { void draw(); } Which is the correct implementation? Public class DrawList implements Sortable, Implements Drawable { public void sort() { /*implementation*/} public void draw() { /*implementation*/} ] Public class DrawList extends Sortable, Drawable { public void sort() { /*implementation*/} public void draw() { /*implementation*/} } Public class DrawList implements Sortable, Drawable { public void sort() { /*implementation*/} public void draw() { /*implementation*/} } Public class DrawList extends Sortable, extends Sortable, extends Drawable { public void sort() { /*implementation*/ } public void draw() { /* implementation */}.
A developer needs to find information about @future methods that were invoked. From which system monitoring feature can the developer see this information? Scheduled Jobs Apex Jobs Background Jobs Asynchronous Jobs.
A change set deployment from a sandbox to production fails due to a failure in a managed package unit test. The developer spoke with the managed package owner and they determined it is a false positive and can be ignored. What should the developer do to successfully deploy? Select "Run local tests" to run all tests in the org that are not in the managed package. Select "Fast Deploy" to run only the tests that are in the change set. Select "Run local tests" to run only the tests that are in the change set. Edit the managed package’s unit test.
A developer needs to include a Visualforce page in the detail section of a page layout for the Account object, but does not see the page as an available option in the Page Layout Editor. Which attribute must the developer include in the <apex:page> tag to ensure the Visualforce page can be embedded in a page layout? standardController= "Account" extensions= "AccountController" controller= "Account" action= "AccountId".
What is the impact of declaring an Apex class using the "without sharing" keywords? Only records owned by the current user can be updated. Sharing restrictions for the current user are bypassed. Records created by the class cannot have sharing rules. The class can only be used by users with developer rights.
Using DescribeSObjectResult, which Apex method can a developer use to determine if the current user can edit records for an object? canUpdate() canEdit() isUpdateable() isEditable().
A developer needs to create an audit trail for records that are sent to the recycle bin. Which type of trigger is most appropriate to create? after delete after undelete before undelete before delete.
Which three areas can a Lightning component be used in the Lightning Experience? Lightning Report page Lightning Connect page Lightning Record Page Lightning Community Page Lightning Home page.
How can a developer get all of the available record types for the current user on the Case object? Use DescribeSObjectResult of the Case object. Use SOQL to get all Cases. Use DescribeFieldResult of the Case.RecordType field. Use Case.getRecordTypes().
An Account trigger updates all related Contacts and Cases each time an Account is saved using the following two DML statements: update allContacts; update allCases; What is the result if the Case update exceeds the governor limit for maximum number of DML records? The Account save fails and no Contacts or Cases are updated. The Account save succeeds and no Contacts or Cases are updated. The Account save succeeds, Contacts are updated, but Cases are not. The Account save is retried using a smaller trigger batch size.
A company has a custom object named Region. Each Account in Salesforce can only be related to one Region at a time, but this relationship is optional. Which type of relationship should a developer use to relate an Account to a Region? Parent-Child. Hierarchical Lookup Master-Detail.
How can a developer warn users of SOQL governor limit violations in a trigger? Use Messaging.SendEmail() to continue the transaction and send an alert to the user after the number of SOQL queries exceeds the limit. Use PageReference.setRedirect() to redirect the user to a custom Visualforce page before the number of SOQL queries exceeds the limit. Use Limits.getQueries() and display an error message before the number of SOQL queries exceeds the limit. Use ApexMessage.Message() to display an error message after the number of SOQL queries exceeds the limit.
Which two declarative process automation features can be directly invoked when a field value changes on a record? (Choose two.) Cloud Flow Designer flows Process Builder processes Validation rules Workflow rules.
Which feature allows a developer to create test records for use in test classes? Documents WebServiceTests HttpCalloutMocks Static Resources.
A developer wants multiple test classes to use the same set of test data. How should the developer create the test data? Reference a test utility class in each test class. Define variables for test records in each test class. Create a Test Setup method for each test class. Use the SeeAllData=true annotation in each test class.
A developer wants to display all of the picklist entries for the Opportunity StageName field and all of the available record types for the Opportunity object on a Visualforce page. Which two actions should the developer perform to get the available picklist values and record types in the controller? (Choose two.) Use Schema.RecordTypeInfo returned by Opportunity.SObjectType.getDescribe().getRecordTypeInfos(). Use Schema.PicklistEntry returned by Opportunity.SObjectType.getDescribe().getPicklistValues (). Use Schema.RecordTypeInfo returned by RecordType.SObjectType.getDescribe().getRecordTypeInfos(). Use Schema.PicklistEntry returned by Opportunity.StageName.getDescribe().getPicklistValues ().
Which situation prevents a developer from setting sharing rules for a custom object? The object’s Sharing Settings is set to Public Read/Write.. The object is on the detail side of a Master-Detail relationship. The developer is not a System Administrator. The object is referenced in an Owner field of a Master-Detail relationship.
A developer wants to store a description of a product that can be entered on separate lines by a user during product setup and later displayed on a Visualforce page for shoppers. Which field type should the developer choose to ensure that the description will be searchable in the custom Apex SOQL queries that are written? Text Area Text Text Area (Long) Text Area (Rich).
An Apex transaction inserts 100 Account records and 2,000 Contact records before encountering a DML exception when attempting to insert 500 Opportunity records. The Account records are inserted by calling the database.insert() method with the allOrNone argument set to false. The Contact and Opportunity records are inserted using the standalone insert statement. How many total records will be committed to the database in this transaction? 2,000 2,100 0 100.
The sales team at Universal Containers would like to see a visual indicator appear on both Account and Opportunity page layouts to alert salespeople when an Account is late making payments or has entered the collections process. What can a developer implement to achieve this requirement without having to write custom code? Formula Field Workflow Rule Quick Action Roll-up Summary Field.
Which governor limit applies to all the code in an Apex transaction? Elapsed SOQL query time Number of classes called Number of new records created Elapsed CPU time.
Given the code below, what can be done so that recordCount can be accessed by a test class, but not by a non-test class? public class MyController { private Integer recordCount; } Change recordCount from private to public. Add the SeeAllData annotation to the test class. Add the TestVisible annotation to recordCount. Add the TestVisible annotation to the MyController class.
A developer can use the debug log to see which three types of information? (Choose three.) HTTP callouts to external systems Database changes Resource usage and limits User login events Actions triggered by time-based workflow.
Managed Packages can be created in which type of org? Developer Sandbox Partial Copy Sandbox Unlimited Edition Developer Edition.
Requirements state that a child record is deleted when its parent is deleted, and a child can be moved to a different parent when necessary. Which type of relationship should be built between the parent and child objects in Schema builder to support these requirements? Master-Detail relationship Child relationship Lookup relationship from the parent to the child Lookup relationship from the child to the parent.
Which tag should a developer include when styling from external CSS is required in a Visualforce page? apex:includeStyles apex:includeScript apex:require apex:stylesheet.
Which type of code represents the Model in the MVC architecture when using Apex and Visualforce pages? A Controller Extension method that saves a list of Account records Custom JavaScript that processes a list of Account records A list of Account records returned from a Controller Extension method A Controller Extension method that uses SOQL to query for a list of Account records.
What is the debug output of the following Apex code? Decimal theValue; System.debug(theValue); 0.0 null Undefined 0.
A developer needs to provide a way to mass edit, update, and delete records from a list view. In which two ways can this be accomplished? (Choose two.) Create a new Visualforce page and Apex Controller for the list view that provides mass edit, update, and delete functionality. Download a managed package from the AppExchange that provides customizable Enhanced List Views and buttons. Download an unmanaged package from the AppExchange that provides customizable mass edit, update, and delete functionality. Configure the user interface and enable both inline editing and enhanced lists.
Which two practices should be used for processing records in a trigger? (Choose two.) Use a Map to reduce the number of SOQL calls. Use @future methods to handle DML operations. Use a Set to ensure unique values in a query filter. Use (callout=true) to update an external system.
Which two statements are acceptable for a developer to use inside procedural loops? (Choose two.) delete contactList; contactList.remove(i); Contact con = new Contact(); Account a = [SELECT Id, Name FROM Account WHERE Id = :con.AccountId LIMIT 1];.
Which two statements are true about Apex code executed in Anonymous Blocks? (Choose two.) The code runs with the permissions of the user specified in the runAs() statement. The code runs with the permissions of the logged in user. The code runs in system mode having access to all objects and fields. All DML operations are automatically rolled back. Successful DML operations are automatically committed.
From which two locations can a developer determine the overall code coverage for a sandbox? (Choose two.) The Apex Test Execution page The Test Suite Run panel of the Developer Console The Apex classes setup page The Tests tab of the Developer Console.
Which three statements are true regarding cross-object formulas? (Choose three.) Cross-object formulas can reference fields from objects that are up to 10 relationships away. Cross-object formulas can reference fields from master-detail or lookup relationships. Cross-object formulas can reference child fields to perform an average. Cross-object formulas can expose data the user does not have access to in a record. Cross-object formulas can be referenced in roll-up summary fields.
For which example task should a developer use a trigger rather than a workflow rule? To set the Name field of an expense report record to Expense and the Date when it is saved To send an email to a hiring manager when a candidate accepts a job offer To notify an external system that a record has been modified To set the primary Contact on an Account record when it is saved.
Which feature should a developer use to update an inventory count on related Product records when the status of an Order is modified to indicate it is fulfilled? Process Builder process Lightning component Visualforce page Workflow rule.
A company wants to create an employee rating program that allows employees to rate each other. An employee’s average rating must be displayed on the employee record. Employees must be able to create rating records, but are not allowed to create employee records. Which two actions should a developer take to accomplish this task? (Choose two.) Create a trigger on the Rating object that updates a fields on the Employee object. Create a lookup relationship between the Rating and Employee object. Create a roll-up summary field on the Employee and use AVG to calculate the average rating score. Create a master-detail relationship between the Rating and Employee objects.
Which two SOSL searches will return records matching search criteria contained in any of the searchable text fields on an object? (Choose two.) [FIND ‘Acme*’ IN ANY FIELDS RETURNING Account, Opportunity]; [FIND ‘Acme*’ RETURNING Account, Opportunity]; [FIND ‘Acme*’ IN ALL FIELDS RETURNING Account, Opportunity]; [FIND ‘Acme*’ IN TEXT FIELDS RETURNING Account, Opportunity];.
What is the data type returned by the following SOSL search? [FIND ‘Acme*’ IN NAME FIELDS RETURNING Account, Opportunity]; List<List<Account>, List<Opportunity>> Map<sObject, sObject> List<List<sObject>> Map<Id, sObject>.
A Platform Developer needs to implement a declarative solution that will display the most recent Closed Won date for all Opportunity records associated with an Account. Which field is required to achieve this declaratively? Roll-up summary field on the Opportunity object Cross-object formula field on the Opportunity object Roll-up summary field on the Account object Cross-object formula field on the Account object.
Which three statements are true regarding the @isTest annotation? (Choose three.) A method annotated @isTest(SeeAllData=true) in a class annotated @isTest(SeeAllData=false) has access to all org data. A method annotated @isTest(SeeAllData=false) in a class annotated @isTest(SeeAllData=true) has access to all org data. A class containing test methods counts toward the Apex code limit regardless of any @isTest annotation. Products and Pricebooks are visible in a test even if a class is annotated @isTest(SeeAllData=false). Profiles are visible in a test even if a class is annotated @isTest(SeeAllData=false).
For which three items can a trace flag be configured? (Choose three.) Apex Trigger Apex Class Process Builder User Visualforce.
A developer is asked to create a custom Visualforce page that will be used as a dashboard component. Which three are valid controller options for this page? (Choose three.) Use a standard controller. Use a standard controller with extensions. Use a custom controller with extensions. Do not specify a controller. Use a custom controller.
A developer wrote a unit test to confirm that a custom exception works properly in a custom controller, but the test failed due to an exception being thrown. Which step should the developer take to resolve the issue and properly test the exception? Use try/catch within the unit test to catch the exception. Use the finally bloc within the unit test to populate the exception. Use the database methods with all or none set to FALSE. Use Test.isRunningTest() within the custom controller.
Which SOQL query successfully returns the Accounts grouped by name? SELECT Type, Max(CreatedDate) FROM Account GROUP BY Name SELECT Name, Max(CreatedDate) FROM Account GROUP BY Name SELECT Id, Type, Max(CreatedDate) FROM Account GROUP BY Name SELECT Type, Name, Max(CreatedDate) FROM Account GROUP BY Name LIMIT 5.
What are three characteristics of static methods? (Choose three.) Initialized only when a class is loaded A static variable outside of the scope of an Apex transaction Allowed only in outer classes Allowed only in inner classes Excluded from the view state for a Visualforce page.
What are two uses for External IDs? (Choose two.) To create relationships between records imported from an external system. To create a record in a development environment with the same Salesforce ID as in another environment To identify the sObject type in Salesforce To prevent an import from creating duplicate records using Upsert.
A developer needs to create a Visualforce page that displays Case data. The page will be used by both support reps and support managers. The Support Rep profile does not allow visibility of the Customer_Satisfaction__c field, but the Support Manager profile does. How can the developer create the page to enforce Field Level Security and keep future maintenance to a minimum? Create one Visualforce Page for use by both profiles. Use a new Support Manager permission set. Create a separate Visualforce Page for each profile. Use a custom controller that has the with sharing keywords.
When an Account’s custom picklist field called Customer Sentiment is changed to a value of "Confused", a new related Case should automatically be created. Which two methods should a developer use to create this case? (Choose two.) Process Builder Apex Trigger Custom Button Workflow Rule.
Which two number expressions evaluate correctly? (Choose two.) Double d = 3.14159; Integer I = 3.14159; Decimal d = 3.14159; Long l = 3.14159;.
How can a developer set up a debug log on a specific user? It is not possible to setup debug logs for users other than yourself. Ask the user for access to their account credentials, log in as the user and debug the issue. Create Apex code that logs code actions into a custom object. Set up a trace flag for the user, and define a logging level and time period for the trace.
How should a developer create a new custom exception class? public class CustomException extends Exception{} CustomException ex = new (CustomException)Exception(); public class CustomException implements Exception{} (Exception)CustomException ex = new Exception();.
A developer wants to override a button using Visualforce on an object. What is the requirement? The controller or extension must have a PageReference method. The standardController attribute must be set to the object. The action attribute must be set to a controller method. The object record must be instantiated in a controller or extension.
A lead object has a custom field Prior_Email__c. The following trigger is intended to copy the current Email into the Prior_Email__c field any time the Email field is changed: trigger test on Lead (before update) { for(Lead Id: trigger.new) { if(Id.Email !=trigger.oldMap.get(Id.Id).email) { Id.Prior_Email__c = trigger.old,ap.get(Id.Id).email; } } } Which type of exception will this trigger cause? A null reference exception A compile time exception A DML exception A limit exception when doing a bulk update.
A developer is asked to set a picklist field to ‘Monitor’ on any new Leads owned by a subnet of Users. How should the developer implement this request? Create an after insert Lead trigger. Create a before insert Lead trigger. Create a Lead Workflow Rule Field Update. Create a Lead formula field.
Why would a developer consider using a custom controller over a controller extension? To increase the SOQL query governor limits. To implement all of the logic for a page and bypass default Salesforce functionality To leverage built-in functionality of a standard controller To enforce user sharing settings and permissions.
How should a developer avoid hitting the governor limits in test methods? Use @TestVisible on methods that create records. Use Test.loadData() to load data from a static resource. Use @IsTest (SeeAllData=true) to use existing data. Use Test.startTest() to reset governor limits.
Which three declarative fields are correctly mapped to variable types in Apex? (Choose three.) Number maps to Decimal. Number maps to Integer. TextArea maps to List of type String. Date/Time maps to Dateline. Checkbox maps to Boolean.
Which three tools can deploy metadata to production? (Choose three.) Change Set from Developer Org Force.com IDE Data Loader Change Set from Sandbox Metadata API.
A developer needs to display all of the available fields for an object. In which two ways can the developer retrieve the available fields if the variable myObject represents the name of the object? (Choose two.) Use myObject.sObjectType.getDescribe().fieldSet() to return a set of fields. Use mySObject.myObject.fields.getMap() to return a map of fields. Use Schema.describeSObjects(new String[]{myObject})[0].fields.getMap() to return a map of fields. Use getGlobalDescribe().get(myObject).getDescribe().fields.getMap() to return a map of fields.
Which three options allow a developer to use custom styling in a Visualforce page? (Choose three.) <apex:stylesheet> tag Inline CSS <apex:style>tag <apex:stylesheets>tag A static resource.
Which set of roll-up types are available when creating a roll-up summary field? COUNT, SUM, MIN, MAX AVERAGE, SUM, MIN, MAX SUM, MIN, MAX AVRAGE, COUNT, SUM, MIN, MAX.
What should a developer do to meet these requirements? Create a lookup field on the Construction Job object to the Machinery object. Create a lookup field on the Machinery object to the Construction Job object. Create a junction object with Master-Detail Relationship to both the Machinery object and the Construction Job object. Create a Master-Detail Lookup on the Machinery object to the Construction Job object.
What is a benefit of using an after insert trigger over using a before insert trigger? An after insert trigger allows a developer to bypass validation rules when updating fields on the new record. An after insert trigger allows a developer to insert other objects that reference the new record. An after insert trigger allows a developer to make a callout to an external service. An after insert trigger allows a developer to modify fields in the new record without a query.
A developer created a Visualforce page and a custom controller with methods to handle different buttons and events that can occur on the page. What should the developer do to deploy to production? Create a test class that provides coverage of the Visualforce page. Create a test page that provides coverage of the Visualforce page. Create a test page that provides coverage of the custom controller. Create a test class that provides coverage of the custom controller.
Which tool allows a developer to send requests to the Salesforce REST APIs and view the responses? REST resource path URL Workbench REST Explorer Developer Console REST tab Force.com IDE REST Explorer tab.
A developer is asked to create a PDF quote document formatted using the company’s branding guidelines, and automatically save it to the Opportunity record. Which two ways should a developer create this functionality? (Choose two.) Install an application from the AppExchange to generate documents. Create a Visualforce page with custom styling. Create an email template and use it in Process Builder. Create a visual flow that implements the company’s formatting.
Which approach should a developer use to add pagination to a Visualforce page? A StandardController The Action attribute for a page The extensions attribute for a page A StandardSetController.
A developer created a Lightning component to display a short text summary for an object and wants to use it with multiple Apex classes. How should the developer design the Apex classes? Have each class define method getObject() that returns the sObject that is controlled by the Apex class. Extend each class from the same base class that has a method getTextSummary() that returns the summary. Have each class implement an interface that defines method getTextSummary() that returns the summary. Have each class define method getTextSummary() that returns the summary.
Have each class define method getObject() that returns the sObject that is controlled by the Apex class. When a record needs to be created When multiple records related to the triggering record need to be updated When a post to Chatter needs to be created When an action needs to be taken on a delete or undelete, or before a DML operation is executed.
Using the Schema Builder, a developer tries to change the API name of a field that is referenced in an Apex test class. What is the end result? The API name is not changed and there are no other impacts. The API name of the field and the reference in the test class is changed. The API name of the field is changed, and a warning is issued to update the class. The API name of the field and the reference in the test class is updated.
An org has a single account named ‘NoContacts’ that has no related contacts. Given the query: List<Account> accounts = [Select ID, (Select ID, Name from Contacts) fromAccount where Name=‘NoContacts’]; What is the result of running this Apex? accounts[0].contacts is invalid Apex. accounts[0].contacts is an empty Apex. accounts[0].contacts is Null. A QueryException is thrown.
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 three.) Use a Visual Workflow. Use a validation rule. Use the Process Automation Settings. Use a Trigger.
In a single record, a user selects multiple values from a multi-select picklist. How are the selected values represented in Apex? As a List<String>with each value as an element in the list As a Stringwith each value separated by a comma As a Stringwith each value separated by a semicolon As a Set<String>with each value as an element in the set.
How should a developer prevent a recursive trigger? Use a “one trigger per object” pattern. Use a static Boolean variable. Use a trigger handler. Use a private Boolean variable.
A newly hired developer discovers that there are multiple triggers on the case object. What should the developer consider when working with triggers? Developers must dictate the order of trigger execution. Trigger execution order is based on creation date and time. Unit tests must specify the trigger being tested. Trigger execution order is not guaranteed for the same sObject.
A Visualforce page is required for displaying and editing Case records that includes both standard and custom functionality defined in an Apex class called myControllerExtension. The Visualforce page should include which <apex:page> attribute(s) to correctly implement controller functionality? controller=“Case” and extensions=“myControllerExtension” extensions=“myControllerExtension” controller=“myControllerExtension” standardController=“Case” and extensions=“myControllerExtension”.
Which two statements are true about using the @testSetup annotation in an Apex test class? (Choose two.) The @testSetup annotation cannot be used when the @isTest(SeeAllData=True) annotation is used. Test data is inserted once for all test methods in a class. Records created in the @testSetup method cannot be updates in individual test methods. The @testSetup method is automatically executed before each test method in the test class is executed.
Which approach should a developer take to automatically add a “Maintenance Plan” to each Opportunity that includes an “Annual Subscription” when an opportunity is closed? Build a OpportunityLineItem trigger that adds a PriceBookEntry record. Build an OpportunityLineItem trigger to add an OpportunityLineItem record. Build an Opportunity trigger that adds a PriceBookEntry record. Build an Opportunity trigger that adds an OpportunityLineItem record.
Which approach should be used to provide test data for a test class? Query for existing records in the database. Execute anonymous code blocks that create data. Use a test data factory class to create test data Access data in @TestVisibleclass variables.
Which two platform features align to the Controller portion of MVC architecture? (Choose two.) Process Builder actions Workflow rules Standard objects Date fields.
Which two Apex data types can be used to reference a Salesforce record ID dynamically? (Choose two.) ENUM sObject External ID String.
A method is passed a list of generic sObjects as a parameter. What should the developer do to determine which object type (Account, Lead, or Contact, for example) to cast each sObject? Use the first three characters of the sObject ID to determine the sObject type. Use the getSObjectType method on each generic sObject to retrieve the sObject token. Use the getSObjectName method on the sObject class to get the sObject name. Use a try-catch construct to cast the sObject into one of the three sObject types.
Universal Containers wants to back up all of the data and attachments in its Salesforce org once a month. Which approach should a developer use to meet this requirement? Define a Data Export scheduled job. Use the Data Loader command line. Schedule a report. Create a Schedulable Apex class.
A developer needs to implement the functionality for a service agent to gather multiple pieces of information from a customer in order to send a replacement credit card. Which automation tool meets these requirements? Lightning Component Flow Builder Process Builder Approval Process.
A developer is asked to create a Visualforce page that displays some Account fields as well as fields configured on the page layout for related Contacts. How should the developer implement this request? Use the <apex:include>tag. Use the <apex:relatedList>tag. Add a method to the standard controller. Create a controller extension.
Report abuse Terms of use
HOME
CREATE TEST
COMMENTS
STADISTICS
RECORDS
Author's Tests