最上級のCRT-450試験問題Salesforceテスト最高成績で最速合格をゲットせよ! [Q86-Q111]

Share

最上級のCRT-450試験問題Salesforceテスト最高成績で最速合格をゲットせよ!

試験準備には最適なCRT-450試験問題2025年最新のSalesforce Developers究極な202問があります

質問 # 86
The Account object has a custom Percent field, Rating, defined with a length of 2 with 0 decimal places. An Account record has the value of 50% in its Rating field and is processed in the Apex code below after being retrieved from the database with SOQL.

What is the value of acctScore after this code executes?

  • A. 0
  • B. 1
  • C. 2
  • D. 3

正解:B


質問 # 87
A developer created a custom order management app that uses an Apex class. The order is represented by an Order object and an Orderltem object that has a master-detail relationship to Order. During order processing, an order may be split into multiple orders.
What should a developer do to allow their code to move some existing Orderltem records to a new Order record?

  • A. Create a junction object between Orderltem and Order.
  • B. Select the Allow reparenting option on the master-detail relationship.
  • C. Add without sharing to the Apex class declaration.
  • D. Change the master-detail relationship to an external lookup relationship.

正解:B


質問 # 88
An org has an existing flow that edits an Opportunity with an Update Records element. A developer must update the flow to also create a Contact and store the created Contact's ID on the Opportunity.
Which update must the developer make in the flow?

  • A. Add a new Get Records element.
  • B. Add a new Update Records element.
  • C. Add a new Roll Back Records element.
  • D. Add a new Create Records element.

正解:D

解説:
To update the flow to create a Contact and store the Contact's ID on the Opportunity:
Option D: Add a new Create Records element.
Steps:
Add Create Records Element: Configure it to create a Contact and store the newly created Contact's ID in a variable.
Update Opportunity: Use the existing Update Records element or add a new one to update the Opportunity with the Contact's ID.
Reference:
"Use the Create Records element to create records in your flow."
- Salesforce Help: Create Records Element
Why Other Options Are Incorrect:
Option A: An Update Records element cannot create a new Contact.
Option B: A Get Records element retrieves existing records but does not create new ones.
Option C: Roll Back Records is used to undo record changes in the flow transaction.


質問 # 89
A developer is alerted to an issue with a custom Apex trigger that is causing records to be duplicated.
What is the most appropriate debugging approach to troubleshoot the issue?

  • A. Disable the trigger in production and test to see if the issue still occurs.
  • B. Review the Historical Event logs to identify the source of the issue.
  • C. Add system.debug statements to the code to track the execution flow and identify the issue.
  • D. Use the Apex Interactive Debugger to step through the code and identify the issue.

正解:C


質問 # 90
Which two statements are true about Getter and Setter methods as they relate to Visualforce?

  • A. Setter methods always have to be declared global.
  • B. Getter methods pass values from a controller to a page.
  • C. There is no guarantee for the order in which Getter methods are called.
  • D. A corresponding Setter method is required for each Getter method.

正解:B、D


質問 # 91
A developer wants to use all of the functionality provided by the standard controller for an object, but needs to override the Save standard action in a controller extension. Which two are required in the controller extension class?

  • A. Create a method named Save with a return data type of PageReference.
  • B. Define the class with a constructor that creates a new instance of the StandardController class.
  • C. Create a method that references this.superSave()
  • D. Define the class with a constructor that takes an instance of StandardController as a parameter.

正解:A、D


質問 # 92
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 master-detail relationship
  • B. Create a junction object to relate many engines to many parts through a lookup relationship
  • C. Create a lookup relationship to represent how each part relates to the parent engine object.
  • D. Create a master-detail relationship to represent the one-to-many model of engines to parts.

正解:A


質問 # 93
A developer needs to create a baseline set of data (Account, Contacts, Products, Assets) for an entire suite allowing them to test independent requirements for various types of Salesforce Cases.
Which approach can efficiently generate the required data for each unit test?

  • A. Add $ IsTest (seeAllDatatrue) at the start of the unit test class.
  • B. Create a mock using the Stub APL.
  • C. Create test data before Test.startTest in the unit test.
  • D. Use &TestSteup with a void method.

正解:D

解説:
To efficiently generate the required data for each unit test, the best approach is to use @TestSetup with a void method. This annotation allows you to create common test data that is available for all test methods in the test class. The data is rolled back after each test method, so you don't have to worry about deleting or modifying it.
This way, you can avoid duplicating code and improve performance by reducing the number of DML operations. The other options are not correct because:
* Creating test data before Test.startTest in the unit test means that you have to repeat the same code for every test method that needs the same data. This can make your test class longer and harder to maintain.
It also consumes more DML statements and governor limits.
* Creating a mock using the Stub API is useful for testing callouts or interfaces, not for creating test data.
A mock object is a fake object that simulates the behavior of a real object. It does not persist any data in the database.
* Adding @IsTest(seeAllData=true) at the start of the unit test class is not a good practice, as it makes your test methods depend on the data in the org. This can cause your tests to fail or behave inconsistently if the data changes or is not available. It also exposes your test methods to the risk of violating data privacy or security policies. References:
* Generate Data for Tests
* Testing Best Practices
* Free Salesforce Platform Developer 1 Practice Exam (With Answers)


質問 # 94
A developer must create a DrawList class that provides capabilities defined in the Sortable and Drawable interfaces.

Which is the correct implementation?

  • A.
  • B.
  • C.
  • D.

正解:B


質問 # 95
What are two use cases for executing Anonymous Apex code? Choose 2 answers

  • A. To schedule an Apex class to run periodically
  • B. To delete 15,000 inactive Accounts In a single transaction after a deployment
  • C. To run a batch Apex class to update all Contacts
  • D. To add unit test code coverage to an org

正解:A、C


質問 # 96
A Visual force page displays two fields named Phone Number and Email.User1 has access to Phone Number, but not to Email.User2 has access to Email, but not Phone NumberA developer needs to ensure that User1 can only see Phone Number, and User2 can only see Email.Which method can the developer use to achieve this?

  • A. Schema isUpdateable() method.
  • B. Schema isAccessible() method.
  • C. Schema isCreateable() method.
  • D. Schema isReadable() method.

正解:B


質問 # 97
Which two statements accurately represent the MVC framework implementation in Salesforce? Choose 2 answers

  • A. Validation rules enforce business rules and represent the Controller (C) part of the MVC framework
  • B. Lightning component HTML files represent the Model (M) part of the MVC framework.
  • C. Triggers that create records represent the Model (M) part of the MVC framework.
  • D. Standard and Custom objects used in the app schema represent the View (V) part of the MVC framework

正解:A、C


質問 # 98
A developer has identified 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 datadase.
Which two techniques should the developer implement as a best practice to ensure transaction control and avoid exceeding governor limits?
Choose 2 answers

  • A. D. Use the Reedonly annotation to bypass the number of rows returned by a SOQL.
  • B. Use the System,Limit classto monitor the current CPU governor limit consumption.
  • C. Use partial DML statements to ensure only valid data is committed.
  • D. Use the Database,Savepoint method to enforce database integrity.

正解:C、D

解説:
The correct answers are A and C because they use partial DML statements and the Database.Savepoint method, which are both best practices for ensuring transaction control and avoiding exceeding governor limits.
Partial DML statements allow the developer to specify whether to allow partial success or rollback on failure when performing DML operations on multiple records. This can help avoid hitting the DML row limit (10,000) or the DML statement limit (150) by committing only the valid records and reporting the errors for the invalid ones. The Database.Savepoint method allows the developer to create a savepoint, which is a point in the request that specifies the state of the database at that time. The developer can then use the Database.rollback method to revert the database to the state of a specific savepoint, discarding any changes made after that point. This can help avoid hitting the CPU time limit (10,000 ms) or the heap size limit (6 MB) by rolling back any resource-intensive actions that are not necessary or successful.
The other options are incorrect because they do not provide effective techniques for ensuring transaction control and avoiding exceeding governor limits. Option B uses the System.Limit class to monitor the current CPU governor limit consumption, which is not a best practice. The System.Limit class provides methods to check the current limit usage and the limit value for various governor limits, such as CPU time, heap size, DML statements, etc. However, monitoring the limit consumption does not prevent hitting the limit, and it can also add extra overhead to the code execution. Instead of checking the limit usage, the developer should optimize the code performance and efficiency by using best practices such as bulkification, caching, asynchronous processing, etc. Option D uses the Readonly annotation to bypass the number of rows returned by a SOQL query, which is not a best practice. The Readonly annotation allows the developer to mark an Apex class or method as read-only, which means that it can only query the database and not perform any DML operations. This can increase the maximum number of rows returned by a SOQL query from 50,000 to
1,000,000, but it also restricts the functionality of the class or method. Moreover, bypassing the query row limit does not solve the problem of performing resource-intensive actions in memory by iterating over the result set, which can still hit the CPU time limit or the heap size limit. Instead of using the Readonly annotation, the developer should use best practices such as query filters, selective queries, query limits, etc. to reduce the size of the result set and improve the query performance. References:
* Apex Developer Guide: Using Partial DML
* Apex Developer Guide: Savepoints and Rollbacks
* Apex Developer Guide: Execution Governors and Limits
* Apex Developer Guide: Working with Very Large SOQL Queries


質問 # 99
Which three Salesforce resources can be accessed from a Lightning web component?
Choose 3 answers

  • A. All external libraries
  • B. Static resources
  • C. Third-party web components
  • D. SVG resources
  • E. Content asset files

正解:A、B、D


質問 # 100
What are two considerations for deciding to use a roll-up summary field? Choose 2 answer's partner.

  • A. Roll-up cannot be performed on formula fields.
  • B. Roll-up summary fields do not cause validation rules on the parent object unless that object is edited separately.
  • C. Roll-up cannot be performed on formula fields that use cross-object references or on-the-fly calculations such as NOW().
  • D. Roll-up summary can be performed on formula fields, but if their formula contains an #Error result, it may affect the summary value.

正解:C、D


質問 # 101
Which two queries can a developer use in a Visualforce controller to protect against SOQL injection vulnerabilities? Choose 2 answers

  • A. String qryName = % + String.escapeSingleQuotes(name)+ % ;
    String qryString = SELECT Id FROM Contact WHERE Name LIKE :qryNAme ;
    List queryResults = Database.query(qryString);
  • B. String qryString = SELECT Id FROM Contact WHERE Name LIKE :qryNAme ; List queryResults = Database.query(qryString);
  • C. String qryName = % + name % ;
    String qryString = SELECT Id FROM Contact WHERE Name LIKE :qryNAme ;
    List queryResults = Database.query(qryString);
  • D. String qryName = % + String.enforceSecurityChecks(name)+ % ;
    String qryString = SELECT Id FROM Contact WHERE Name LIKE :qryNAme ;
    List queryResults = Database.query(qryString);

正解:A、C


質問 # 102
What should a developer use to implement an automatic Approval Process submission for Cases?

  • A. A Workflow Rule
  • B. Scheduled Apex
  • C. Process Builder
  • D. An Assignment Rule

正解:C


質問 # 103
A platform developer at Universal Containers needs to create a custom button for the Account object that, when clicked, will perform a series of calculations and redirect the user to a custom Visualforce page.
Which three attributes need to be defined with values in the <apex:page> tag to accomplish this?
(Choose three.)

  • A. readOnly
  • B. renderAs
  • C. action
  • D. standardController
  • E. extensions

正解:B、C、D


質問 # 104
What is a capability of the <ltng:require> tag that is used for loading external Javascript libraries in Lightning Component? (Choose three.)

  • A. Loading files from Documents.
  • B. Specifying loading order.
  • C. Loading scripts in parallel.
  • D. Loading externally hosted scripts.
  • E. One-time loading for duplicate scripts.

正解:B、C、E


質問 # 105
What is an example of a polymorphic lookup field in Salesforce?

  • A. The Parentid field on the standard Account object
  • B. The LeadId and ContactId fields on the standard Campaign Member object
  • C. A custom field, Link__c, on the standard Contact object that looks up to an Account or a Campaign
  • D. The Whatld field on the standard Event object

正解:D

解説:
A polymorphic lookup field is a relationship field that can reference one of several different types of objects.
For example, the Who relationship field of a Task can be a Contact or a Lead. The WhatId field on the standard Event object is another example of a polymorphic lookup field, as it can reference any object that allows activities, such as Account, Opportunity, Case, etc. To determine the type of the referenced object, you can use the What.Type field in a SOQL query. You can also use the TYPEOF clause to filter or select fields based on the object type. References:
* Understanding Relationship Fields and Polymorphic Fields
* Working with Polymorphic Relationships in SOQL Queries
* Lookup Search Cheat Sheet


質問 # 106
Given the following code snippet, that is part of a custom controller for a Visualforce page:

In which two ways can the try/catchbe enclosed to enforce object-level permissions and prevent the DML statement from being executed if the current logged-in user does not have the appropriate level of access to the object? (Choose two.)

  • A. Use if(Schema.sObjectType.Contact.fields.Is_Active__c.isUpdateable())
  • B. Use if(thisContact.OwnerId == User.Info.getUserId())
  • C. Use if(Schema.sObjectType.Contact.isAccessible())
  • D. Use if(Schema.sObjectType.Contact.isUpdateable())

正解:A、D


質問 # 107
A developer deployed a trigger to update the status__c of Assets related to an Account when the Account's status changes and a nightly integration that updates Accounts in bulk has started to fail with limit failures.

What should the developer change about the code to address the failure while still having the code update all of the Assets correctly?

  • A. Change the getAssetsToUpdate method to process all Accounts in one call and call it outside of the for loop that starts on line 03.
  • B. Move all of the logic to a Queveable class that queries for and updates the Assets and call it from the trigger.
  • C. Add List<asset> assets = [SELECT id, Status_ FROM WHERE AccountId = : acctId] to line 14 and iterate over the assets list in the for loop on line 15.;
  • D. Add a LIMIT clause to the SOQL query on line 16 to limit the number of Assets queried for an Account.

正解:A


質問 # 108
An Approval Process is defined in the Expense_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 enter the approval process individually. Which approach should be used to ensure the business requirement is met?

  • A. 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.
  • B. 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.
  • C. Create a Process Builder on Expense_Report__c to mark the related Expense_Item__c as submittable and trigger on Expense_item__c to submit the records for approval.
  • D. Create two Process Builder, 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.

正解:D


質問 # 109
A developer created a new trigger that inserts a Task when a new Lead is created. After deploying to production, an outside integration chat reads task records is periodically reporting errors.
Which change should the developer make to ensure the integration is not affected with minimal impact to business logic?

  • A. Use the Database method with all or None set to false
  • B. Deactivate the trigger before the integration runs.
  • C. Use a try-catch block after the insert statement.
  • D. Remove the Apex class from the integration user's profile.

正解:A

解説:
Using the Database method with all or None set to false allows the developer to insert the Task records without throwing an exception if some of them fail. This way, the integration can read the task records that were successfully inserted, and the developer can handle the failed records in the trigger or elsewhere. The other options are either too disruptive to the business logic (A and C) or do not prevent the exception from occurring (B). References: Database Methods, Bulk Exception Handling, Trigger Exceptions


質問 # 110
A developer considers the following snippet of code:

Based on this code, what is the value of x?

  • A. 0
  • B. 1
  • C. 2
  • D. 3

正解:D


質問 # 111
......

注目のCRT-450豪華セット試験ガイドで最速合格を目指そう:https://www.jpntest.com/shiken/CRT-450-mondaishu

CRT-450試験ガイド豪華セットで最速合格を目指そう:https://drive.google.com/open?id=1iQT-eZQzUvBwBAiFcrPpQim11Oe4yHDi

弊社を連絡する

我々は12時間以内ですべてのお問い合わせを答えます。

オンラインサポート時間:( UTC+9 ) 9:00-24:00
月曜日から土曜日まで

サポート:現在連絡