Salesforce Certified Einstein Analytics and Discovery Consultant — Question 3
A large company is rolling out Einstein Analytics to their field sales. They have a well-defined role hierarchy where everyone is assigned to an appropriate node on the hierarchy.
An individual Sales rep should be able to view all opportunities that she/he owns or as part of the account team or opportunity team. The Sales Manager should be able to view all opportunities for the entire Sales team. Similarly, the Sales Vice President should be able to view opportunities for everyone who rolls up in that hierarchy.
The opportunity dataset has a field called ‘OwnerId’ which represents the opportunity owner.
Given this information, how can an Einstein Consultant implement the above requirements?
Answer options
- A. As part of the dataflow, use computeRelative on the RoleId field to create an attribute called ‘ParentRoleIDs’ on the opportunity dataset and apply following security predicate: ‘ParentRoleIDs’ = = “$User.UserRoleId” || ‘OwnerId’ = = “$User.Id”.
- B. As part of the dataflow, use computeExpression on the RoleId field to create an attribute called ‘ParentRoleIDs’ on the opportunity dataset and apply following security predicate: ‘ParentRoleIDs’ = = “$User.UserRoleId” || ‘OwnerId’ = = “$User.Id”.
- C. As part of the dataflow, use the flatten operation on the role hierarchy and create a multivalue attribute called ‘ParentRoleIDs’ on the opportunity dataset and apply following security predicate: ‘ParentRoleIDs’ = = “$User.UserRoleId” && ‘OwnerId’ = = “$User.Id”.
- D. As part of the dataflow, use the flatten operation on the role hierarchy and create a multivalue attribute called ‘ParentRoleIDs’ on the opportunity dataset and apply following security predicate: ‘ParentRoleIDs’ = = “$User.UserRoleId” || ‘TeamMember.Id’ = = “User.Id” || ‘OwnerId’ = = “$User.Id”.
Correct answer: C
Explanation
The correct answer is C because it ensures that the Sales representative can view opportunities they own and that the Sales Manager can access opportunities for their entire team through the use of the appropriate security predicate. Options A and B incorrectly use a logical OR instead of AND, which does not meet the requirement for the Sales Manager's access. Option D adds unnecessary complexity by including ‘TeamMember.Id’, which is not required for the Sales representative's access.