+ Start a Discussion
Chris ParisChris Paris 

Validation Rule to prevent transfer records outside of role

I have a requirement to create a validation rule to prevent transferring of records outside of a role.  I would like to allow users of a role to transfer objects owned by users in their role.  Any users outside of their role would not have permission to transfer records.  

Currently, our security is set to private and we enable view access to all accounts,leads,opportunity objects.  We have in place sharing rules per object per role, that give access to users within their respective role to edit those objects.  People outside that immediate role, do not have access to edit those objects.

Since transfer record is a binary option controlled on profiles, is there a validation rule that can be put on objects to control the transferring permission for the need described above?


Thanks!
kanagaraj Arjunan 3kanagaraj Arjunan 3
Hi Chris

You can achive this using lookup filter.
 set thr filter criteria as below in Account owner field.
Filter Criteria:    Account Owner: Role ID EQUALS Current User: Role ID

User-added image
Chris ParisChris Paris
Hi Kanagaraj,

This filter does prevent users from transferring records to other users outside of their roles but doesn't prevent them from transferring an account into the user's name (even if they are not in the same role).  

The solution provides this : 

Mary in Role A
Joe in Role A
Bob in Role B

Mary can transfer an account that Bob owns into her name, but cannot transfer the record to Bob.  Mary can transfer an account now owned by her to Joe ( because they are in the same role).

Is there anyway to prevent Mary from transferring an account owned by Bob into her name and still allow Mary to transfer to Joe?

*Additionally with the filter, it doesn't allow admins to override the account ownership and transfer accounts amongst roles.

Thanks!