• Shuffle
    Toggle On
    Toggle Off
  • Alphabetize
    Toggle On
    Toggle Off
  • Front First
    Toggle On
    Toggle Off
  • Both Sides
    Toggle On
    Toggle Off
  • Read
    Toggle On
    Toggle Off
Reading...
Front

Card Range To Study

through

image

Play button

image

Play button

image

Progress

1/61

Click to flip

Use LEFT and RIGHT arrow keys to navigate between flashcards;

Use UP and DOWN arrow keys to flip the card;

H to show hint;

A reads text to speech;

61 Cards in this Set

  • Front
  • Back

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. A contact initialized to null.


B. An error that no rows are found.


C. An empty List of Contacts.


D. A Contact with empty values.

B. An error that no rows are found.

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. After Committing to database.


B. Before Trigger execution.


C. After Trigger execution.


D. Before Committing to database.

A. After Committing to database.

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 objects) {


accounts = (List ) objects;


}




D. public MyController (ApexPages.StandardController stdController) {


account = (Account) stdController.getRecord();


}

A. public MyController () {account = new Account () ;}

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 adding a second standard controller to the page for the parent record.


B. By using a roll-up formula field on the child record to include data from the parent record.


C. By using SOQL on the Visualforce page to query for data from the parent record.


D. By using merge field syntax to retrieve data from the parent record.

D. By using merge field syntax to retrieve data from the parent record.

When can a developer use a custom Visualforce page in a Force.com application? (Choose 2)




A. To generate a PDF document with application data


B. To create components for dashboards and layouts


C. To deploy components between two organizations


D. To modify the page layout settings for a custom object

A. To generate a PDF document with application data




B. To create components for dashboards and layouts

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 required Visualforce component.


B. Create a formula field.


C. Create a required comments field.


D. Create a validation rule.

D. Create a validation rule.



How can a developer avoid exceeding governor limits when using Apex Triggers? (Choose 2)




A. By using a helper class that can be invoked from multiple triggers


B. By using Maps to hold data from query results


C. By using the Database class to handle DML transactions


D. By performing DML transactions on a list of sObjects.

B. By using Maps to hold data from query results




D. By performing DML transactions on a list of sObjects.



Which scenario is invalid for execution by unit tests?




A. Executing methods for negative test scenarios


B. Loading the standard Pricebook ID using a system method


C. Loading test data in place of user input for Flows.


D. Executing methods as different users.

C. Loading test data in place of user input for Flows.

A developer has the following code:




try {


List nameList;


Account a;


String s = a.Name;


nameList.add(s);


}




catch (ListException le ) {


System.debug(' List Exception ');


}


catch (NullPointerException npe) {


System.debug(' NullPointer Exception ');


}


catch (Exception e) {


System.debug(' Generic Exception ');


}




What message will be logged?




A. List Exception


B. NullPointer Exception


C. Generic Exception


D. No message is logged

B. NullPointer Exception

Which action can a developer perform in a before update trigger? (Choose 2)




A. Display a custom error message in the application interface.


B. Change field values using the Trigger.new context variable.


C. Delete the original object using a delete DML operation.


D. Update the original object using an update DML operation.

A. Display a custom error message in the application interface.




B. Change field values using the Trigger.new context variable.

A developer needs to create records for the object Property__c. The developer creates the following code block:




List propertiesToCreate = helperClass.createProperties();


try {


// line 3


}


catch (Exception exp ) {


//exception handling


}




Which line of code would the developer insert at line 3 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. insert propertiesToCreate;


C. Database.insert(propertiesToCreate, System.ALLOW_PARTIAL);


D. Database.insert(propertiesToCreate);

A. Database.insert(propertiesToCreate, false);

A developer needs to know if all tests currently pass in a Salesforce environment.




Which feature can the developer use? (Choose 2)




A. ANT Migration Tool


B. Workbench Metadata Retrieval


C. Salesforce UI Apex Test Execution


D. Developer Console



C. Salesforce UI Apex Test Execution




D. Developer Console

Where can the custom roll-up summary fields be created using Standard Object relationships (Choose 3)




A. On Opportunity using Opportunity Product records.


B. On Account using Case records.


C. On Quote using Order records.


D. On Campaign using Campaign Member records.


E. On Account using Opportunity records.

A. On Opportunity using Opportunity Product records.




D. On Campaign using Campaign Member records.




E. On Account using Opportunity records.

What is the proper process for an Apex Unit Test?




A. Query for test data using SeeAllData = true. Call the method being tested. Verify that the results are correct.


B. Query for test data using SeeAllData = true. Execute runAllTests(). Verify that the results are correct.


C. Create data for testing. Execute runAllTests(). Verify that the results are correct.


D. Create data for testing. Call the method being tested. Verify that the results are correct.

D. Create data for testing. Call the method being tested. Verify that the results are correct.

How would a developer use Schema Builder to delete a custom field from the Account object that was required for prototyping but is no longer needed?




A. Delete the field from Schema Builder and then all references in the code will be removed.


B. Remove all references in the code and then the field will be removed from Schema Builder.


C. Mark the field for deletion in Schema Builder and then delete it from the declarative UI.


D. Remove all references from the code and then delete the custom field from Schema Builder.

D. Remove all references from the code and then delete the custom field from Schema Builder.

Which statement would a developer use when creating test data for products and pricebooks?




A. Id pricebookId = Test.getStandardPricebookId();


B. Pricebook pb = new Pricebook();


C. IsTest(SeeAllData = false);


D. List objList = Test.loadData(Account.sObjectType, 'myResource');

A. Id pricebookId = Test.getStandardPricebookId();

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. Nothing. The task is automatically displayed on the Account page.


B. Nothing. The Task cannot be related to an Account and a Contact.


C. Create a Workflow rule to relate the Task to the Contact's Account.


D. Create an Account formula field that displays the Task information.

A. Nothing. The task is automatically displayed on the Account page.

The Sales Management team hires a new intern.


The intern is not allowed to view Opportunities, but needs to see the Most Recent Closed Date of all child Opportunities when viewing an Account record.




What would a developer do to meet this requirement?




A. Create a trigger on the Account object that queries the Close Date of the most recent Opportunities.


B. Create a Workflow rule on the Opportunity object that updates a field on the parent Account.


C. Create a formula field on the Account object that performs a MAX on the Opportunity Close Date field.


D. Create a roll-up summary field on the Account object that performs a MAX on the Opportunity Close Date field.

D. Create a roll-up summary field on the Account object that performs a MAX on the Opportunity Close Date field.

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


B. 7


C. 5


D. 3



C. 5

A developer runs the following anonymous code block:




List acc = [SELECT Id FROM Account LIMIT 10];




Delete acc;




Database.emptyRecycleBin(acc);




system.debug(Limits.getDMLStatements() + ', ' + Limits.getLimitDMLStatements() );




What is the result?




A. 2, 150


B. 150, 2


C. 11, 150


D. 150, 11

A. 2, 150

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)




A. Download a Managed Package from the AppExhange that provides a custom Visualforce page to modify.


B. Copy the standard page and then make a new Visualforce page for Product data entry.


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 Product data entry.

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 Product data entry.

A developer wants to display all of 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)




A. Use Schema.PicklistEntry returned by Case.Status.getDescribe().getPicklistValues().


B. Use Schema.RecordTypeInfo returned by Case.sObjectType.getDescribe().getRecordTypeInfos().


C. Use SOQL to query Case records in the org to get all the RecordType values available for Case.


D. Use SOQL to query case records in the org to get all values for the Status picklist field.

A. Use Schema.PicklistEntry returned by Case.Status.getDescribe().getPicklistValues().




B. Use Schema.RecordTypeInfo returned by Case.sObjectType.getDescribe().getRecordTypeInfos().

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 preferred way to load this test data into Salesforce?




A. By using Documents.


B. By using HttpCalloutMocks.


C. By using WebServiceTests.


D. By using Static Resources.

D. By using Static Resources.

Which statement about change set deployments is accurate? (Choose 3)




A. They use an all or none deployment model.


B. They require a deployment connection.


C. They ca be used to transfer Contact records.


D. They can be used to deploy custom settings data.


E. They can be used only between related organizations.

A. They use an all or none deployment model.




B. They require a deployment connection.




E. They can be used only between related organizations.

Which user can edit a record after it has been locked for approval? (Choose 2)




A. Any user with a higher role in the hierarchy


B. A user who is assigned as the current approver


C. Any user who approved the record previously


D. An administrator

B. A user who is assigned as the current approver




D. An administrator

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 Messaging.sendEmail() to continue toe transaction and send an alert to the user after the number of DML statements is exceeded.


C. By using AmexMessage.Messages() to display an error message after the number of DML statements is exceeded.


D. By using Limits.getDMLRows() and then displaying an error message before the number of DML statements is exceeded.

D. By using Limits.getDMLRows() and then displaying an error message before the number of DML statements is exceeded.

A developer creates a custom controller and custom Visualforce page by using the following code block:




public class myController {


public String myString;


public String getMyString() {


return 'getmyString';


}


public String getStringMethod1() {


return myString;


}


public String getStringMethod2() { if (myString == null)


myString = 'Method2';


return myString;


}


}





{!myString}, {!StringMethod1}, {!StringMethod2}, {!myString}







What does the user see when accessing the custom page?




A. getMyString , , Method2 , getMystring


B. , , Method2 , getMyString


C. , , Method2,


D. getMyString , , ,

A. getMyString , , Method2 , getMystring

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 TestVisible attribute to the Apex class


B. Add the SeeAllData attribute to the test methods.


C. Add the TestVisible attribute to the apex methods.


D. Add the SeeAllData attribute to the test class.

C. Add the TestVisible attribute to the apex methods.

What is the benefit of the Lightning Component framework?




A. Better integration with Force.com sites.


B. More pre-built components to replicate the Salesforce look and feel.


C. More centralized control via server-side logic.


D. Better performance for custom Salesforce 1 Mobile apps.

B. More pre-built components to replicate the Salesforce look and feel.

Which data type or collection of data types can SOQL statements populate or evaluate to? (Choose 3)




A. A single sObject


B. An integer


C. A string


D. A list of sObjects


E. A Boolean

A. A single sObject




B. An integer




D. A list of sObjects

In the Lightning Component framework, which resource can be used to fire events?




A. JavaScript controller actions


B. Third-party web service code.


C. Third-party JavaScript code.


D. Visualforce controller actions.

A. JavaScript controller actions




C. Third-party JavaScript code.

What is a valid source and destination pair that can send or receive change sets? (Choose 2)




A. Developer Edition to Sandbox


B. Sandbox to Production


C. Sandbox to Sandbox


D. Developer Edition to Production

B. Sandbox to Production




C. Sandbox to Sandbox

Where can debug log filter settings be set? (Choose 2)




A. On the monitored user's name.


B. The Show More link on the debug log's record.


C. The Log Filters tab on a class or trigger detail page.


D. The Filters link by the monitored user's name within the web UI.



B. The Show More link on the debug log's record.




C. The Log Filters tab on a class or trigger detail page.

What is the capability of a StandardSetController? (Choose 2)




A. It allows pages to perform pagination with large record sets.


B. It enforces field-level security when reading large record sets.


C. It extends the functionality of a standard or custom controller.


D. It allows pages to perform mass updates of records.

A. It allows pages to perform pagination with large record sets.




D. It allows pages to perform mass updates of records.

When loading data into an operation, what can a developer do to match records to update existing records? (Choose 2)




A. Match an auto-generated Number field to a column in the imported file.


B. Match an external Id Text field to a column in the imported file.


C. Match the Name field to a column in the imported file.


D. Match the Id field to a column in the imported file.

B. Match an external Id Text field to a column in the imported file.




D. Match the Id field to a column in the imported file.

What is a capability of the Force.com IDE? (Choose 2)




A. Edit metadata components.


B. Run Apex tests.


C. Roll back deployments.


D. Download debug logs.

A. Edit metadata components.




B. Run Apex tests.

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


B. In a Standard Controller.


C. In a Custom Controller.


D. In a Controller Extension.

D. In a Controller Extension.

Which type of code represents the Controller in MVC architecture on the Force.com platform? (Choose 2)




A. JavaScript that is used to make a menu item display itself.


B. A static resource that contains CSS and images.


C. Custom Apex and JavaScript coda that is used to manipulate data.


D. StandardController system methods that are referenced by Visualforce.

C. Custom Apex and JavaScript coda that is used to manipulate data.




D. StandardController system methods that are referenced by Visualforce.

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( Database.getQueryLocator( 'SELECT Id FROM Account LIMIT 1'));




B. ApexPages.StandardController controller = new ApexPages.StandardController( [SELECT Id FROM Account LIMIT 1]);




C. ApexPages.StandardController controller = new ApexPages.StandardController( Database.getQueryLocator( 'SELECT Id FROM Account LIMIT 1'));




D. ApexPages.StandardController controller = new ApexPages.StandardController( [SELECT Id FROM Account LIMIT 1]);

A. ApexPages.StandardSetController controller = new ApexPages.StandardSetController( Database.getQueryLocator( 'SELECT Id FROM Account LIMIT 1'));

Which declarative method helps ensure quality data? (Choose 3)




A. Validation Rules


B. Workflow alerts


C. Exception Handling


D. Lookup Filters


E. Page Layouts

A. Validation Rules




D. Lookup Filters




E. Page Layouts

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)




A. A cross-object formula field on the Account object.


B. An Apex trigger on the Account object.


C. A Workflow Rule on the Account object.


D. A Process Builder on the Account object.

B. An Apex trigger on the Account object.




D. A Process Builder on the Account object.

In which order does Salesforce execute events upon saving a record?




A. Before Triggers; Validation Rules; After Triggers; Assignment Rules; Workflow Rules; Commit




B. Validation Rules; Before Triggers; After Triggers; Workflow Rules; Assignment 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

A. Before Triggers; Validation Rules; After Triggers; Assignment Rules; Workflow Rules; Commit

Which statement about the Lookup Relationship between a Custom Object and a Standard Object is correct?




A. The Custom Object inherits security from the referenced Standard Object.


B. The Lookup Relationship on the Custom Object can prevent the deletion of the Standard Object.


C. The Custom Object will be deleted when the referenced Standard Object is deleted.


D. The Lookup Relationship cannot be marked as required on the page layout for the Custom Object.

B. The Lookup Relationship on the Custom Object can prevent the deletion of the Standard Object.

What is an accurate statement about variable scope? (Choose 3)




A. Parallel blocks can use the same variable name.


B. A variable can be defined at any point in a block.


C. Sub-blocks cannot reuse a parent block's variable name.


D. Sub-blocks can reuse a parent block's variable name if it's value is null.


E. A static variable can restrict the scope to the current block of its value is null.

A. Parallel blocks can use the same variable name.




B. A variable can be defined at any point in a block.




C. Sub-blocks cannot reuse a parent block's variable name.

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 isInsertable() method.


B. By using the isCreatable() method.


C. By using the hasAccess() method.


D. By using the canCreate() method.

B. By using the isCreatable() method.

Which statement should a developer avoid using inside procedural loops? (Choose 2)




A. System.debug('Amount of CPU time (in ms) used so far: ' + Limits.getCpuTime() );


B. List contacts = [SELECT Id, Salutation, FirstName, LastName, Email FROM Contact WHERE AccountId = :a.Id];


C. if(o.accountId == a.id)


D. update contactList;

B. List contacts = [SELECT Id, Salutation, FirstName, LastName, Email FROM Contact WHERE AccountId = :a.Id];




D. update contactList;



On which object can an administrator create a roll-up summary field?




A. Any object that is on the detail side of a master-detail relationship.


B. Any object that is on the child side of a lookup relationship.


C. Any object that is on the parent side of a lookup relationship.


D. Any object that is on the master side of a master-detail relationship.

D. Any object that is on the master side of a master-detail relationship.

How would a developer determine if a CustomObject__c record has been manually shared with the current user in Apex?




A. By querying the role hierarchy.


B. By calling the isShared() method for the record.


C. By querying CustomObject__Share.


D. By calling the profile settings of the current user.

C. By querying CustomObject__Share.

What is a capability of formula fields? (Choose 3)




A. Generate a link using the HYPERLINK function to a specific record in a legacy system.


B. Display the previous values for a field using the PRIORVALUE function.


C. Return and display a field value from another object using the VLOOKUP function.


D. Determine if a datetime field has passed using the NOW function.


E. Determine which of three different images to display using the IF function.

A. Generate a link using the HYPERLINK function to a specific record in a legacy system.




D. Determine if a datetime field has passed using the NOW function.




E. Determine which of three different images to display using the IF function.

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'sprofile 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. {!$Setup.Url_Settings__C.URL__c}

Which type of information is provided by the Checkpoints tab in the Developer Console? (Choose 2)




A. Namespace


B. Time


C. Exception


D. Debug Statement

A. Namespace




B. Time

What is a good practice for a developer to follow when writing a trigger? (Choose 2)




A. Using @future methods to perform DML operations.


B. Using the Map data structure to hold query results by ID.


C. Using the Set data structure to ensure distinct records.


D. Using synchronous callouts to call external systems.

B. Using the Map data structure to hold query results by ID.




C. Using the Set data structure to ensure distinct records.

What is an important consideration when developing in a multi-tenant environment?




A. Governor limits prevent tenants from impacting performance in multiple orgs on the same instance.


B. Unique domain names take the place of namespaces for code developed for multiple orgs on multiple instances.


C. Polyglot persistence provides support for a global, multilingual user base in multiple orgs on multiple instances.


D. Org-wide data security determines whether other tenants can see data in multiple orgs on the same instance.

A. Governor limits prevent tenants from impacting performance in multiple orgs on the same instance.

Which trigger event allows a developer to update fields in the Trigger.new list without using an additional DML statement? (Choose 2)




A. After update.


B. Before insert.


C. Before update.


D. After insert.

B. Before insert.




C. Before update.

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 String with each value separated by a comma.


B. As a Set with each value as an element in the set.


C. As a List with each value as an element in the list.


D. As a String with each value separated by a semicolon.

D. As a String with each value separated by a semicolon.

What is a valid way of loading external JavaScript files into a Visualforce page? (Choose 2)




A. Using an (apex:includeScript)* tag. \>


B. Using an (apex:define)* tag.


C. Using a (link)* tag.


D. Using a (script)* tag.




*For this question, replace ( ) with less/greater than symbols.

A. Using an (apex:includeScript)* tag.




D. Using a (script)* tag.




*For this question, replace ( ) with less/greater than symbols.



Where would a developer build a managed package?




A. Developer Sandbox


B. Unlimited Edition


C. Partial Copy Sandbox


D. Developer Edition

D. Developer Edition

What is the value of x after the code segment executes?




String x = 'A';


Integer i = 10;


if ( i < 15 ) {


i = 15;


x = 'B';


}


else if ( i < 20 ) {


x = 'C';


}


else {


x = 'D';


}




A. D


B. A


C. B


D. C

C. B

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)




A. Create a lookup relationship between the Candidate and Interview objects.


B. Create a master-detail relationship between the Candidate and Interview objects.


C. Create a trigger on the Interview objects that update a field on the Candidate object.


D. Create a roll-up summary field on the Candidate object that counts Interview records.

A. Create a lookup relationship between the Candidate and Interview objects.




C. Create a trigger on the Interview objects that update a field on the Candidate object.

A developer has a block of code that omits any statements that indicate whether the code block should execute with or without sharing.




A. HTTP Callouts


B. Apex Controllers


C. Anonymous Blocks


D. Apex Triggers

A. HTTP Callouts

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. System Assert statements that do not increase code coverage contribute important feedback in unit tests.


C. Triggers do not require any unit tests in order to deploy them from sandbox to production


D. Increased test coverage requires large test classes with many lines of code in one method.

B. System Assert statements that do not increase code coverage contribute important feedback in unit tests.