12. Salesforce Platform Developer 1(450)
B.Lookup notice it's Account not Contact
A company has a custom object named Warehouse. Each Warehouse record has a distinct record owner, and is related to a parent Account in Salesforce. Which kind of relationship would a developer use to relate the Account to the Warehouse? A.One -to -Many B.Lookup C.Master -Detail D.Parent -Child
B.A custom exception C..addError() E.A try/catch construct
A developer creates a method in an Apex class and needs to ensure that errors are handled properly. What would the developer use? (There are three correct answers.) A.ApexPages.addErrorMessage() B.A custom exception C..addError() D.Database.handleException() E.A try/catch construct
b. By using Static Resources
A developer needs to ensure there is sufficient test coverage for an Apex method that interacts with Accounts. The developer needs to create test data. What is the preffered way to load this test data into Salesforce? a. By using WebServiceTests b. By using Static Resources c. By using HttpCalloutMocks d. By using Documents
c. Download an Unmanaged Package from the AppExchange that provides a custom Visualforce page to modify. d. Create a new Visualforce page and an Apex controller to provide data entry.
A developer needs to provide a Visualforce page that lets users enter Product specific details during a Sales cycle. How can this be accomplished? Choose 2 answers a. Copy the standard page and then make a new Visualforce page for Product data entry. b. Download a Managed Package from the AppExchange that provides a custom Visualforce page to modify. c. Download an Unmanaged Package from the AppExchange that provides a custom Visualforce page to modify. d. Create a new Visualforce page and an Apex controller to provide data entry.
b. Use Schema.PicklistEntry returned by Case.Status.getDescribe().getPicklistValues() c. Use Schema.RecordTypeInfo returned by Case.sObjectType.getDescribe().getRecordTypeInfos()
A developer wants to display all the available record types for a case Object. The developer also wants to display the picklist values for the Case.Status field. The Case Object and the Case.Status field are on a Custom Visualforce page. Which action can the developer perform to get the record types and picklist values in the controller? Choose 2 answers. a. Use SOQL to query Case records in the org to get all the RecordType values available for Case b. Use Schema.PicklistEntry returned by Case.Status.getDescribe().getPicklistValues() c. Use Schema.RecordTypeInfo returned by Case.sObjectType.getDescribe().getRecordTypeInfos() d. Use SOQL to query Case records in the org to get all values for the Status picklist field
A.Create a method that creates valid Account records, and call this method from within test methods. B.Create a method that loads valid Account records from a Static Resource, and call this method within test methods.
An org has different Apex Classes that provide Account -related functionality. After a new validation rule is added to the object, many of the test methods fail. What can be done to resolve the failures and reduce the number of code changes needed for future validation rules? Choose 2 answers: A.Create a method that creates valid Account records, and call this method from within test methods. B.Create a method that loads valid Account records from a Static Resource, and call this method within test methods. C.Create a method that performs a callout for a valid Account record, and call this method from within test methods. D.Create a method that queries for valid Account records, and call this method from within test methods.
b. By performing DML transactions on lists of sObjects d. By using Maps to hold data from query results
How can a developer avoid exceeding governor limits when using an Apex Trigger? Choose 2 answers a. By using a helper class that can be invoked from multiple triggers b. By performing DML transactions on lists of sObjects c. By using the Database class to handle DML Transactions d. By using Maps to hold data from query results
d. By using the isCreatable() method
How can a developer determine, from the DescribeSObjectResult, if the current user will be able to create records for an object in Apex? a. By using the hasAccess() method b. By using the isInsertable() method c. By using the canCreatable() method d. By using the isCreatable() method
A. By using a PageReference with a partial or full URL. B. By using the Page object and a Visualforce page name.
How can a developer refer to, or instantiate a PageReference in Apex? Choose 2 answers A. By using a PageReference with a partial or full URL. B. By using the Page object and a Visualforce page name. C. By using the ApexPages.Page() method with a Visualforce page name. D. By using the PageReference.Page() method with a partial or full URL.
c. By querying CustomObject__share
How would a developer determine if a CustomObject__c record has been manually shared with the current user in Apex? a. By calling the profile settings of the current user b. By calling the isShared() method for the record c. By querying CustomObject__share d. By querying the role hierarchy.
b. As a String with each value separated by a semicolon
In a single record, a user selects multiple values from a multi-select picklist. How are the selected values represented in Apex? a. As a Set<String> with each value as an element in the set b. As a String with each value separated by a semicolon c. As a String with each value separated by a comma d. As a List<String> with each value as an element in the list
D.JavaScript
In the Lightning Component framework, where is client-side controller logic contained? A.Apex B.Visualforce C.HTML D.JavaScript
b. Before Triggers;Validation Rules; After Triggers; Assignment Rules;Workflow Rules; Commit
In which order does Salesforce execute events upon saving a record? a. Validation Rules; Before Triggers; After Triggers; Workflow Rules;Assignment Rules; Commit b. Before Triggers;Validation Rules; After Triggers; Assignment Rules;Workflow Rules; Commit c. Before Triggers;Validation Rules; After Triggers; Workflow Rules;Assignment Rules; Commit d. Validation Rules; Before Triggers; After Triggers; Assignment Rules; Workflow Rules; Commit
B.Decimal
To which primitive data type in Apex is a currency field atomically assigned? A.Integer B.Decimal C.Double D.Currency
a. It allows pages to perform mass updates of records b. It allows pages to perform pagination with large record sets
What is a capability of a StandardSetController? Choose 2 answers a. It allows pages to perform mass updates of records b. It allows pages to perform pagination with large record sets c. It enforces field-level security when reading large record sets d. It extends the functionality of a standard or custom controller
A.Formula fields can reference fields from master-detail or lookup parent relationships. B.Formula fields can expose data the user does not have access to in a record. E.Formula fields can reference fields from objects that are up to 10 relationships away.
What is a capability of cross-object formula fields? Choose 3 answers A.Formula fields can reference fields from master-detail or lookup parent relationships. B.Formula fields can expose data the user does not have access to in a record. C.Formula fields can be used in three roll-up summaries per object. D.Formula fields can reference fields in a collect of records from a child relationship. E.Formula fields can reference fields from objects that are up to 10 relationships away.
a. Execute Anonymous Apex code, Create/Edit code, view Debug Logs.
What is a capability of the Developer Console? a. Execute Anonymous Apex code, Create/Edit code, view Debug Logs. b. Execute Anonymous Apex code, Run REST API, create/Edit code. c. Execute Anonymous Apex code, Create/Edit code, deploy code changes. d. Execute Anonymous Apex code, Run REST API, deploy code changes.
B. Run Apex tests. D. Edit metadata components.
What is a capability of the Force.com IDE? Choose 2 answers A. Roll back deployments. B. Run Apex tests. C. Download debug logs. D. Edit metadata components.
B.Account[] acctList = new List{new Account()}
What is a valid Apex statement? A.Map conMap = (SELECT Name FROM Contact); B.Account[] acctList = new List{new Account()} C.Integer w, x, y = 123, z = 'abc', D.Private static constant Double rate = 775;
c. Governor limits prevent tenants from impacting performance in multiple orgs on the same instance
What is an important consideration when developing in a multi-tenant environment? a. Org-wide data security determines whether other tenants can see data in multiple orgs on the same instance. b. Unique domain names take the place of namespace for code developed for multiple orgs on multiple instances. c. Governor limits prevent tenants from impacting performance in multiple orgs on the same instance d. Polyglot persistence provides support for a global, multilingual user base in multiple orgs in multiple instances
d. DEBUG
What is the minimum log level needed to see user-generated debug statements? a. FINE b. INFO c. WARN d. DEBUG
c. To create components for dashboards and layouts d. To generate a PDF document with application data
When can a developer use a custom Visualforce page in a Force.com application? Choose 2 answers a. To deploy components between two organizations b. To modify the page layout settings for a custom object c. To create components for dashboards and layouts d. To generate a PDF document with application data
b. Match the Id field to a column in the imported file c. Match an external Id Text field to a column in the imported file.
When loading data into an organization, what can a developer do to match records to update existing records? Choose 2 answers a. Match the Name field to a column in the imported file b. Match the Id field to a column in the imported file c. Match an external Id Text field to a column in the imported file. d. Match an auto-generated Number field to a column in the imported file
d. Developer Edition
Where would a developer build a managed package? a. Partial Copy Sandbox b. Developer Sandbox c. Unlimited Edition d. Developer Edition
D.If (trigger.IsInsert) { dowork();}
Which code segment can be used to control when the dowork()method is called? A.For (triggerIsRunning t : trigger.new) {dowork();} B.If (trigger.IsRunning) { dowork(); } C.For (trigger.IsInsert t : trigger.new) { dowork(); } D.If (trigger.IsInsert) { dowork();}
a. A single sObject d. A list of sObjects e. An Integer
Which data type or collection of data types can SOQL statements populate or evaluate to? Choose 3 answers a. A single sObject b. A string c. A Boolean d. A list of sObjects e. An Integer
b. Loading test data in place of user input for Flows.
Which scenario is invalid for execution by unit tests? a. Executing methods for negative test scenarios. b. Loading test data in place of user input for Flows. c. Executing methods as different users d. Loading the standard Pricebook ID using a system method
C.LastName
Which standard field needs to be populated when a developer inserts new Contact records programmatically? A.Accountld B.Name C.LastName D.FirstName
D. The Lookup relationship on the Custom Object can prevent the deletion of the Standard Object
Which statement about the lookup relationship between a custom object and a standard object is correct? A. The Custom Object will be deleted when the referenced Standard Object is deleted B. The lookup Relationship cannot be marked as required on the page layout for the Custom Object C. The custom Object inherits security from the referenced Standard Object D. The Lookup relationship on the Custom Object can prevent the deletion of the Standard Object
b. List<Contact> contacts = [select id, salutation, firstname, lastname, email from Contact where accountId = :a.Id] d. Update contactList
Which statement should a developer avoid using inside procedural loops? Choose 2 answers a. if(o.accountid = a.id) b. List<Contact> contacts = [select id, salutation, firstname, lastname, email from Contact where accountId = :a.Id] c. System.debug('Amount of CPU time (in ms) used so far:' + Limits.getCpuTime()); d. Update contactList
a. Id pricebookId = Test.getStandardPricebookId();
Which statement would a developer use when creating test data for products and pricebooks? a. Id pricebookId = Test.getStandardPricebookId(); b. IsTest(SeeAllData=false) c. List objList= Test.loadData(Acccount.sObjectType, ',myResource'); d. Pricebook pb = new pricebook();
a. StandardController system methods that are referenced by Visualforce c. Custom Apex and Javascript code that is used to manipulate data
Which type of code represents the Controller in MVC architecture on the Force.com platform? Choose 2 answers a. StandardController system methods that are referenced by Visualforce b. A static resource that contains CSS and images c. Custom Apex and Javascript code that is used to manipulate data d. Javascript that is used to make a menu item display itself
a. An administrator b. A user who is assigned as the current approver
Which user can edit a record after it has been locked for approval? (Choose 2) a. An administrator b. A user who is assigned as the current approver c. Any user with a higher role in the hierarchy d. Any user who approved the record previously
Which type of information is provided by the Checkpoints tab in the Developer console?Choose 2 answers. a. Time b. Exception c. Debug Statement d. Namespace
a. Time d. Namespace
B. 100 Too Many SOQL Statements, and / or multiple definitions of myAccount there is a limit that 150 times DML in a exceed
A Developer in a salesforce org with 100 Accounts executes the following code using the Developer console; Account myaccount = new Account(Name =' my account '); insert my account; for(Integer x=0; x<150; x++) { Account newAccount = new Account(Name='MyAccount' + x); try{ insert newAccount; } catch(Exception ex){ system.debug(ex); } } insert new Account(Name='MyAccount'); how many accounts are in the org after this code is run? A. 101 B. 100 C. 102 D. 252
b. {!$Setup.Url_Settings__c.URL__c}
A Hierarchy Custom Setting stores a specific URL for each profile in Salesforce. Which statement can a developer use to retrieve the correct URL for the current user´s profile and display this on a Visualforce page? a. {!$Setup.Url_Settings_c.Instance[Profile.Id].URL__c} b. {!$Setup.Url_Settings__c.URL__c} c. {!$Setup.Url_Settings__c[Profile.Id].URL__c} d. {!$Setup.Url_Settings__c[$Profile.Id].URL__c}
b. Create a master-detail relationship in the Application custom object to the Job Postings custom object.
A candidate may apply to multiple jobs at the company Universal Containers by submtting a single application per job posting. Once an application is submitted for a job posting, that application cannot be modified to be resubmitted to a different job posting. What can the administrator do to associate an application with each job posting in the schema for the organization? a. Create a master-detail relationship in the Job Postings custom object to the Applications custom object. b. Create a master-detail relationship in the Application custom object to the Job Postings custom object. c. Create a lookup relationship on both objects to a junction object called Job Posting Applications. d. Create a lookup relationship in the Applications custom object to the Job Postings custom object
D.Create a workflow rule with an outbound message action.
A company that uses a Custom object to track candidates would like to send candidate information automatically to a third -party human resource system when a candidate is hired. What can a developer do to accomplish this task? A.Create an escalation rule to the hiring manager. B.Create an auto response rule to the candidate. C.Create a Process Builder with an outbound message action. D.Create a workflow rule with an outbound message action.
b. Create a lookup relationship between the Candidate and Interview objects. c. Create a trigger on the Interview object that updates a field on the Candidate object. roll-up summary can only be done on master detail. and you can't have independent security with master detail
A company wants a recruiting app that models candidates and interviews; displays the total number of interviews on each candidate record; and defines security on interview records that is independent from the security on candidate records. What would a developer do to accomplish this task? Choose 2 answers. a. Create a roll-up summary field on the Candidate object that counts Inteview records. b. Create a lookup relationship between the Candidate and Interview objects. c. Create a trigger on the Interview object that updates a field on the Candidate object. d. Create a master-detail relationship between the Candidate and Interview objects.
A.Throw new RecordNotFoundException("problem occured"); B.Throw new RecordNotFoundException();
A custom exception "RecordNotFoundException" is defined by the following code of block. public class RecordNotFoundException extends Exception() which statement can a developer use to throw a custom exception? choose 2 answers A.Throw new RecordNotFoundException("problem occured"); B.Throw new RecordNotFoundException(); C.throw RecordNotFoundException("problem occured"); D.Throw RecordNotFoundException();
D. The Apex Trigger is fired more than once. If there are workflow field updates, updates the record again. If the record was updated with workflow field updates, fires before update triggers and after update triggers one more time (and only one more time), in addition to standard validations. Custom validation rules, duplicate rules, and escalation rules are not run again.
A developer creates a Workflow Rule declaratively that updates a field on an object. An Apex update trigger exists for that object. What happens when a user updates a record? A. No changes are made to the data B. Both the Apex Trigger and Workflow Rule are fired only once. C. The Workflow Rule is fired more than once D. The Apex Trigger is fired more than once.
C. Add test methods to existing test classes from previous deployments
A developer creates a new Visualforce page and Apex extension, and writes test classes that exercise 95% coverage of the new Apex extension.Change set deployment to production fails with the test coverage warning: Average test coverage across all Apex classes and triggers is 74%, at least 75% test coverage is required.What can the developer do to successfully deploy the new Visualforce page and extension? A. Create test classes to exercise the Visualforce page markup B. Select Disable Parallel Apex Testing to run all the tests. C. Add test methods to existing test classes from previous deployments D. Select Fast Deployment to bypass running all the tests
b. Add the TestVisible attribute to the Apex methods
A developer creates an Apex class that includes private methods. What can the developer do to ensure that the private methods can be accessed by the test class? a. Add the SeeAllData attribute to the test methods b. Add the TestVisible attribute to the Apex methods c. Add the TestVisible attribute to the Apex class d. Add the SeeAllData attribute to the test class
b. By using Limits.getDMLRows() and then displaying an error message before the number of DML statements is exceeded.
A developer creates an Apex helper class to handle complex trigger logic. How can the helper class warn users when the trigger exceeds DML governor limits? a. By using PageReference.setRedirect() to redirect the user to a custom Visualforce page before the number of DML statements is exceeded. b. By using Limits.getDMLRows() and then displaying an error message before the number of DML statements is exceeded. c. By using ApexMessage.Message() to display an error message after the number of DML statements is exceeded. d. By using Messaging.SendEmail() to continue the transaction and send an alert to the user after the number of DML statements is exceeded.
2. 0 System.LimitException: Too many DML rows: 10001 there is a limit that 10000 records in a exceed
A developer executes the following code in the Developer Console: List<Account> fList = new List <Account> (); For(integer i= 1; I <= 200; i++) { fList.add(new Account ( Name = 'Universal Account ' + i)); } Insert fList; List <Account> sList = new List<Account>(); For (integer I = 201; I <= 20000; i ++) { sList.add(new Account (Name = 'Universal Account ' + i)); } Insert sList; How many accounts are created in the Salesforce organization ? 1. 20000 2. 0 3. 200 4. 1000
b. Anonymous Blocks
A developer has a block of code that omits any statements that indicate whether the code block should execute with or without sharing. What will automatically obey the organization-wide defaults and sharing settings for the user who executes the code in the Salesforce organization? a. Apex Controllers b. Anonymous Blocks c. HTTP Callouts d. Apex Triggers
A.Public ExtendedController(ApexPages.StandardController cntrl) { } C.Test.setCurrentPage(pageRef); D.String nextPage = controller.save().getUrl(); https://developer.salesforce.com/docs/atlas.en-us.pages.meta/pages/pages_controller_error_handling.htm?search_text=Test.setCurrentPage This is a controller statement, not a test class statement
A developer has a single custom controller class that works with a Visualforce Wizard to support creating and editing multiple sObjects. The wizard accepts data from user inputs across multiple Visualforce pages and from a parameter on the initial URL Which statement is unnecessary inside the unit test for the custom controller?Choose 3 A.Public ExtendedController(ApexPages.StandardController cntrl) { } B.ApexPages.currentPage().getParameters().put('input', 'TestValue'); C.Test.setCurrentPage(pageRef); D.String nextPage = controller.save().getUrl();
a. An error that no rows are found
A developer has the following query: Contact c = [SELECT id, firstname, lastname, email FROM Contact WHERE lastname = 'Smith']; What does the query return if there is no Contact with the last name = 'Smith'? a. An error that no rows are found b. An empty List of Contacts c. A contact initialized to null d. A contact with empty
c. Create a junction object to relate many engines to many parts through a master-detail relationship
A developer is creating an application to track engines and their parts. An individual part can be used in different types of engines. What data model should be used to track the data and to prevent orphan records? a. Create a junction object to relate many engines to many parts through a lookup relationship b. Create a master-detail relationship to represent the one-to-many model of engines to parts. c. Create a junction object to relate many engines to many parts through a master-detail relationship d. Create a lookup relationship to represent how each part relates to the parent engine object.
b. In a Controller Extension
A developer needs to create a Visualforce page that will override the Standard Account edit button. The page will be used to validate the account´s address using a SOQL query. The page will also allow the user to make edits to the address. Where would the developer write the Account address verification logic? a. In a Standard Controller b. In a Controller Extension c. In a Custom Controller d. In a Standard Extension
a. Database.insert(propertiesToCreate, false);
A developer needs to create records for the object Property__c. The developer creates the following code block: 01 List<Property__c> propertiesToCreate = helperClass.createProperties(); 02 try{ 03 04 }catch(Exception exp){ 05 //Exception handling 06 } Which line of code would the developer insert at line 03 to ensure that at least some records are created even if a few records have errors and fail to be created? a. Database.insert(propertiesToCreate, false); b. Database.insert (propertiesToCreate, System.ALLOW_PARTIAL); c. insert propertiesToCreate; d. Database.insert(propertiesToCreate);
a. Developer Console c. Salesforce UI Apex Test Execution
A developer needs to know if all tests currently pass in a Salesforce environment. Which feature can the developer use? Choose 2 answers. a. Developer Console b. ANT Migration Tool c. Salesforce UI Apex Test Execution d. Workbench Metadata Retrieval
d. The Invoice should have a Master-Detail relationship to the Account
A developer wants to create a custom object to track Customer Invoices. How should Invoices and Accounts be related to ensure that all Invoices are visible to everyone with access to an Account? a. The Invoice should have a Lookup relationship to the Account. b. The Account should have a Lookup relationship to the Invoice c. The Account should have a Master-Detail relationship to the Invoice. d. The Invoice should have a Master-Detail relationship to the Account
d. Nothing. The Task is automatically displayed on the Account Page.
A developer wants to list all of the Tasks for each Account on the Account detail page. When a Task is created for a Contact, what does the developer need to do to display the Task on the related Account record? a. Create a Workflow Rule to relate the Task to the Contact´s Account b. Nothing. The Task cannot be related to an Account and a Contact c. Create an Account formula field that displays the Task information d. Nothing. The Task is automatically displayed on the Account Page.
d. 1 We can go 1 level down or 5 level up. From parent to Child 1 level and from child to parent 5 levels
A developer writes a SOQL query to find child records for a specific parent. How many levels can be returned in a single query? a. 3 b. 5 c. 7 d. 1
b. After committing to the database
A developer wrote a workflow email alert on case creation so that an email is sent to the case owner manager when a case is created. When will the email be sent? a. Before committing to the database b. After committing to the database c. Before trigger execution d. After trigger execution
d. Create a validation rule
A reviewer is required to enter a reason in the comments field only when a candidate is recommended to be hired. Which action can a developer take to enforce this requirement? a. Create a formula field b. Create a required comments field c. Create a required Visualforce component d. Create a validation rule
a. By using merge field syntax to retrieve data from the parent record
A visualforce page has a standard controller for an object that has a lookup relationship to a parent object. How can a developer display data from the parent record on the page? a. By using merge field syntax to retrieve data from the parent record b. By using SOQL on the Visualforce page to query for data from the parent record c. By using a roll-up formula field on the child record to include data from the parent record d. By adding a second standard controller to the page for the parent record
C.By using an Apex trigger with a DML operation.
An sObject named Application _c has a lookup relationship to another sObject named Position_c. Both Application _c and Position c have a picklist field named Status_c. When the Status c field on Position __c is updated, the Status_c field on Application _c needs to be populated automatically with the same value, and execute a workflow rule on Application c. Flow can a developer accomplish this? A.By changing Application c.Status_c into a roll-up summary field. B.By changing Application c.Status_c into a formula field. C.By using an Apex trigger with a DML operation. D.By configuring a cross-object field update with a workflow.
a. Third-Party Javascript code d. Javascript controller actions
In the Lightning Component framework, which resource can be used to fire events? Choose 2 answers a. Third-Party Javascript code b. Visualforce controller actions c. Third-party web service code d. Javascript controller actions
B. ,, Method2 ,
Public String getStringMethod1 (){ return myString; } public String getStringMethod2 () { if(myString == null) myString ='Method2'; return myString; } } <apex: page controller = "mycontroller"> {!myString},{!StringMethod1}, {!StringMethod2}, {!myString} </apex:page> what does the user see when accessing the custom page? A. getMyString--- B. ,,Method2, C. , ,Method2,getMyString D. getMyString, , Method2,getMyString
B. Utilize the Standard Controller for Position_c and a Controller Extension to query for Review_c data.
The Review_c object have a lookup relationship to the job_Application_c object. The job_Application_c object has a master detail relationship up to the position_c object. The relationship is based on the auto populated defaults? What is the recommended way to display field data from the related Review _C records a Visualforce page for a single Position_c record? Select one of the following: A. Utilize the Standard Controller for Position_c and cross-object Formula Fields on the Job_Application_c object to display Review_c data. B. Utilize the Standard Controller for Position_c and a Controller Extension to query for Review_c data. C. Utilize the Standard Controller for Position_c and expression syntax in the Page to display related Review_c through the Job_Applicacion_c inject. D. Utilize the Standard Controller for Position_c and cross-object Formula Fields on the Review_c object to display Review_c data.
d. Create a roll-up summary field on the Account object that performs a MAX on the Opportunity Close Date field.
The Sales Management team hires a new intern. The intern is not allowed to view Opportunities, but needs to see the Most Recent Closed Date of all child Opportunities when viewing an Account record. What would a developer do to meet this requirement? a. Create a formula field on the Account object that performs a MAX on the Opportunity Close Date field. b. Create a trigger on the Account object that queries the Close Date of the most recent Opportunities. c. Create a Workflow Rule on the Opportunity object that updates a field on the parent Account. d. Create a roll-up summary field on the Account object that performs a MAX on the Opportunity Close Date field.
B.Validation rule
The sales management team requires that the Lead Source field of the Lead record be populated when a Lead is converted. What would a developer use to ensure that a user populates the Lead Source field prior to converting a Lead? A.Process builder B.Validation rule C.Formula field D.Workflow rule
2. It uses a traditional publish-subscribe model. 3. It uses an event-driven architecture 4. It uses an MVC architectural design pattern. Out-of-the-Box Component Set Rich component ecosystem Performance Event-driven architecture Faster development Device-aware and cross browser compatibility
What are benefit of the Lightning Component framework?Choose 3 answers 1. It uses client-side Apex controllers for logic. 2. It uses a traditional publish-subscribe model. 3. It uses an event-driven architecture 4. It uses an MVC architectural design pattern. 5. It uses server-side JavaScript controller for logic.
a. Generate a link using the HYPERLINK function to a specific record in a legacy system b. Determine if a datetime field has passed using the NOW function e. Determine which of three different images to display using IF function NOTE: VLOOKUP and PRIORVALUE is only available in validation rules.
What is a capability of formula fields? Choose 3 answers a. Generate a link using the HYPERLINK function to a specific record in a legacy system b. Determine if a datetime field has passed using the NOW function c. Return and display a field value from another object using the VLOOKUP function d. Display the previous value for a field using the PRIORVALUE function e. Determine which of three different images to display using IF function
b. Using the Set data structure to ensure distinct records c. Using the Map data structure to hold query results by ID
What is a good practice for a developer to follow when writing a trigger? Choose 2 answers a. Using synchronous callouts to call external systems b. Using the Set data structure to ensure distinct records c. Using the Map data structure to hold query results by ID d. Using @future methods to perform DML operations
a. Sandbox to Sandbox b. Sandbox to Production
What is a valid source and destination pair that can send or receive change sets? Choose 2 answers. a. Sandbox to Sandbox b. Sandbox to Production c. Developer Edition to Production d. Developer Edition to Sandbox
A.The default modifier for a class is private. B.Exception classes must end with the word exception
What is a valid statement about Apex classes and interfaces? Choose 2 answers A.The default modifier for a class is private. B.Exception classes must end with the word exception C.A class can have multiple levels of inner classes. D.The default modifier for an interface is private.
a. Sub-blocks cannot reuse a parent block's variable name b. Parallel blocks can use the same variable name d. A variable can be defined at any point in a block
What is an accurate statement about variable scope? Choose 3 answers a. Sub-blocks cannot reuse a parent block's variable name b. Parallel blocks can use the same variable name c. A static variable can restrict the scope to the current block if its values are null d. A variable can be defined at any point in a block e. A Sub-blocks can reuse a parent's block variable name if its value is null
A.Inner class do not inherit the sharing setting from the container class B.Both inner and outer class can be declared as with sharing
What is the accurate statement about with sharing keyword? choose 2 answers A.Inner class do not inherit the sharing setting from the container class B.Both inner and outer class can be declared as with sharing C.Either inner class or outer classes can be declared as with sharing but not both D.Inner class inherit the sharing setting from the container class
a. More pre-bulk components to replicate the Salesforce look and feel
What is the benefit of the Lightining Component Framework? a. More pre-built components to replicate the Salesforce look and feel b. Better integration with Force.com sites. c. Better performance for custom SalesforceI Mobile apps. d. More centralized control via server-side logic.
c. Create data for testing. Call the method being tested. Verify that the results are correct.
What is the proper process for an Apex unit test? a. Query for test data using SeeAllData= true. Execute runAllTests(). Verify that the results are correct. b. Query for test data using SeeAllData= true. Call the method being tested. Verify that the results are correct. c. Create data for testing. Call the method being tested. Verify that the results are correct. d. Create data for testing. Execute runAllTests(). Verify that the results are correct.
1. An error occurs
What is the result of the following code block ?Integer x = 1; Integer Y = 0; While(x < 10) {Y++;} 1. An error occurs 2. Y = 9 3. Y = 10 4. X = 0
B. the Opportunity StandardController for pre -built functionality.
What must the Controller for a Visualforce page utilize to override the Standard Opportunity view button? A. The StandardSetController to support related lists for pagination. B. the Opportunity StandardController for pre -built functionality. C. A callback constructor to reference the StandardController. D.A constructor that intializes a private Opportunity variable.
D.System Assert statements that do not Increase code coverage contribute important feedback in unit tests
When creating unit tests in Apex, which statement is accurate? A.Unit tests with multiple methods result in all methods failing every time one method fails. B.Increased test coverage requires large test classes with many lines of code in one method. C.Triggers do not require any unit tests in order to deploy them from sandbox to production. D.System Assert statements that do not Increase code coverage contribute important feedback in unit tests
a. An Apex trigger on the Account object c. A Process Builder on the Account object
When the value of a field in an account record is updated, which method will update the value of a custom field in all related opportunities? Choose 2 answers. a. An Apex trigger on the Account object b. A Workflow Rule on the Account object c. A Process Builder on the Account object d. A cross-object formula field on the Account object
A.When a Visualforce page needs to replace the functionality of a standard controller. C.When a Visualforce page should not enforce permissions or field-level security.
When would a developer use a custom controller instead of a controller extension? Choose 2 answers: A.When a Visualforce page needs to replace the functionality of a standard controller. B.When a Visualforce page does not reference a single primary object. C.When a Visualforce page should not enforce permissions or field-level security. D.When a Visualforce page needs to add new actions to a standard controller.
a. On Opportunity using Opportunity Product records c. On Account using Opportunity records e. On Campaign using Campaign Member records
Where can custom roll-up summary fields be created using Standard Object relationships? Choose 3 answers a. On Opportunity using Opportunity Product records b. On Quote using Order records c. On Account using Opportunity records d. On Account using Case records e. On Campaign using Campaign Member records
a. Display a custom error message in the application interface d. Change field values usign the Trigger.new context variable
Which action can a developer perform in a before update trigger? Choose 2 answers a. Display a custom error message in the application interface b. Update the original object using an update DML operation c. Delete the original object using a delete DML operation d. Change field values usign the Trigger.new context variable
2. Create a view containing only standard and system objects. 3. Create a custom object and define a lookup relationship on that object
Which actions can a developer perform using the Schema Builder?Choose 2 answers 1. Create a custom field and automatically add it to an existing page layout. 2. Create a view containing only standard and system objects. 3. Create a custom object and define a lookup relationship on that object 4. Create a view of objects and relationships without fields
a. ApexPages.StandardSetController controller = new ApexPages.StandardSetController([SELECT Id FROM Account LIMIT 1]); c. ApexPages.StandardSetController controller = new ApexPages.StandardSetController(Database.getQueryLocator('select Id from Account Limit 1')); StandardController: Constructor not defined: [ApexPages.StandardController].<Constructor>(Database.QueryLocator) Method does not exist or incorrect signature: void getListViewOptions() from the type ApexPages.StandardController
Which code block returns the ListView of an Account object using the following debug statement? System.debug(Controller.getListViewOptions()); a. ApexPages.StandardSetController controller = new ApexPages.StandardSetController([SELECT Id FROM Account LIMIT 1]); b. ApexPages.StandardController controller = new ApexPages.StandardController(Database.getQueryLocator('select Id from Account Limit 1')); c. ApexPages.StandardSetController controller = new ApexPages.StandardSetController(Database.getQueryLocator('select Id from Account Limit 1')); d. ApexPages.StandardController controller = new ApexPages.StandardController([SELECT Id FROM Account LIMIT 1]);
a. Validation rules b. Lookup filters c. Page Layouts
Which declarative method helps ensure quality data? Choose 3 answers a. Validation rules b. Lookup filters c. Page Layouts d. Workflow alerts e. Exception handling
c. Using an <apex:includeScript> tag d. Using a <script> tag
Which is a valid way of loading external Javascript files into a VisualForce page? Choose 2 answers a. Using an <apex:define> tag b. Using a <link> tag c. Using an <apex:includeScript> tag d. Using a <script> tag
a. They require a deployment connection c. They can be used only between related organizations d. They use an all or none deployment model
Which statement about change set deployments is accurate? Choose 3 answers a. They require a deployment connection b. They can be used to transfer Contact records c. They can be used only between related organizations d. They use an all or none deployment model e. They can be used to deploy custom settings data
a. Before Insert c. Before Update
Which trigger event allows a developer to update fields in the Trigger.new list without using an additional DML statement? Choose 2 answers a. Before Insert b. After Insert c. Before Update d. After Update
D.To create an additional set of governor limits during the execution of a single test class.
Why would a developer use Test. startTest( ) and Test.stopTest( )? A.To avoid Apex code coverage requirements for the code between these lines B.To start and stop anonymous block execution when executing anonymous Apex code C.To indicate test code so that it does not Impact Apex line count governor limits. D.To create an additional set of governor limits during the execution of a single test class.
A. Public MyController() { account a = new Account(); }
what is an accurate constructor for a custom controller named "MyController"? A. public MyController(){ account = new Account(); } B. Public MyController(SObject obj){ account = (Account) obj; } C. public MyController(List<SObject> objects) { accounts = (List<Account>)objects; } D. Public MyController(ApexPages.Standardcontroller stdcontroller) { account = (Account) stdcontroller.getRecord(); }