Salesforce CRT-450 Exam Practice Questions (P. 2)
- Full Access (440 questions)
- One Year of Premium Access
- Access to one million comments
- Seamless ChatGPT Integration
- Ability to download PDF files
- Anki Flashcard files for revision
- No Captcha & No AdSense
- Advanced Exam Configuration
Question #11
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?
Detail relationship to a timecard.
Which approach should the developer use to accomplish this declaratively?
- AA Visualforce page that calculates the total number of hours for a timecard and displays it on the pageMost Voted
- BA Roll-Up Summary field on the Timecard Object that calculates the total hours from timecard entries for that timecard
- CA Process Builder process that updates a field on the timecard when a timecard entry is created
- DAn Apex trigger that uses an Aggregate Query to calculate the hours for a given timecard and stores it in a custom field
Correct Answer:
B
B
send
light_mode
delete
Question #12
A developer encounters APEX heap limit errors in a trigger.
Which two methods should the developer use to avoid this error? (Choose two.)
Which two methods should the developer use to avoid this error? (Choose two.)
- AUse the transient keyword when declaring variables.
- BQuery and store fields from the related object in a collection when updating related objects.
- CRemove or set collections to null after use.Most Voted
- DUse SOQL for loops instead of assigning large queries results to a single collection and looping through the collection.Most Voted
Correct Answer:
AD
AD
send
light_mode
delete
Question #13
Which approach should be used to provide test data for a test class?
- AQuery for existing records in the database.
- BExecute anonymous code blocks that create data.
- CUse a test data factory class to create test data.Most Voted
- DAccess data in @TestVisible class variables.
Correct Answer:
C
C
send
light_mode
delete
Question #14
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?
- ABuild a OpportunityLineItem trigger that adds a PriceBookEntry record.
- BBuild an OpportunityLineItem trigger to add an OpportunityLineItem record.
- CBuild an Opportunity trigger that adds a PriceBookEntry record.
- DBuild an Opportunity trigger that adds an OpportunityLineItem record.Most Voted
Correct Answer:
D
D
send
light_mode
delete
Question #15
Which two statements are true about using the @testSetup annotation in an Apex test class? (Choose two.)
- AThe @testSetup annotation cannot be used when the @isTest(SeeAllData=True) annotation is used.Most Voted
- BTest data is inserted once for all test methods in a class.Most Voted
- CRecords created in the @testSetup method cannot be updates in individual test methods.
- DThe @testSetup method is automatically executed before each test method in the test class is executed.
Correct Answer:
AD
AD
send
light_mode
delete
Question #16
What is the requirement for a class to be used as a custom Visualforce controller?
- AAny top-level Apex class that has a constructor that returns a PageReference
- BAny top-level Apex class that extends a PageReference
- CAny top-level Apex class that has a default, no-argument constructorMost Voted
- DAny top-level Apex class that implements the controller interface
Correct Answer:
D
D
send
light_mode
delete
Question #17
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?
The Visualforce page should include which <apex:page> attribute(s) to correctly implement controller functionality?
- Acontroller=ג€Caseג€ and extensions=ג€myControllerExtensionג€
- Bextensions=ג€myControllerExtensionג€
- Ccontroller=ג€myControllerExtensionג€
- DstandardController=ג€Caseג€ and extensions=ג€myControllerExtensionג€Most Voted
Correct Answer:
D
D
send
light_mode
delete
Question #18
A newly hired developer discovers that there are multiple triggers on the case object.
What should the developer consider when working with triggers?
What should the developer consider when working with triggers?
- ADevelopers must dictate the order of trigger execution.
- BTrigger execution order is based on creation date and time.
- CUnit tests must specify the trigger being tested.
- DTrigger execution order is not guaranteed for the same sObject.Most Voted
Correct Answer:
D
D
send
light_mode
delete
Question #19
How should a developer prevent a recursive trigger?
- AUse a ג€one trigger per objectג€ pattern.
- BUse a static Boolean variable.
- CUse a trigger handler.
- DUse a private Boolean variable.
Correct Answer:
B
B
send
light_mode
delete
Question #20
Which three options can be accomplished with formula fields? (Choose three.)
- AGenerate a link using the HYPERLINK function to a specific record.Most Voted
- BDisplay the previous value for a field using the PRIORVALUE function.
- CDetermine if a datetime field value has passed using the NOW function.Most Voted
- DReturn and display a field value from another object using the VLOOKUP function.
- EDetermine which of three different images to display using the IF function.Most Voted
Correct Answer:
ACE
ACE
send
light_mode
delete
All Pages
