Valid Data-Architect Dumps shared by ExamDiscuss.com for Helping Passing Data-Architect Exam! ExamDiscuss.com now offer the newest Data-Architect exam dumps, the ExamDiscuss.com Data-Architect exam questions have been updated and answers have been corrected get the newest ExamDiscuss.com Data-Architect dumps with Test Engine here:
Universal Containers (UC) has an open sharing model for its Salesforce users to allow all its Salesforce internal users to edit all contacts, regardless of who owns the contact. However, UC management wants to allow only the owner of a contact record to delete that contact. If a user does not own the contact, then the user should not be allowed to delete the record. How should the architect approach the project so that the requirements are met?
Correct Answer: A
To allow only the owner of a contact record to delete that contact, the data architect should create a "before delete" trigger to check if the current user is not the owner. The trigger can use the UserInfo.getUserId() method to get the current user's ID and compare it with the OwnerId field of the contact record. If they are not equal, the trigger can add an error to the record and prevent it from being deleted. The other options are not suitable for meeting the requirements, as they would either restrict the edit access or delete access for all users, regardless of ownership.