function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Brian BartlettBrian Bartlett 

I want a trigger to populate the Case Owners "Managers" eMail

Hello,
I have been able to populate the record owners "Managers" e-mail on some objects using workflow but on the Case Object I get an error telling me we are out of resources. When I contacted SFDC Support they advised I do this with a Trigger, so I need some help for a newbe (me) trying to write a Trigger.
I have a custom field on the Case object Owners.Managers.eMail__c , I want a trigger that populates the Managers eMail in this field, I also want the Trigger to update the Managers eMail when the Case Owner changes.
Andrew EchevarriaAndrew Echevarria
Hey Brian,

If you're out of resources, you will encounter this issue in the future as well and will need to write another trigger. Or if something breaks, you'll have to revise your trigger. For this reason, it's best you understand how triggers work rather than have someone provide one for you.

Below is a very helpful video that I used to write my very first trigger. If you take a look and write a trigger, I'd be more than happy to help you optamize it if it doesn't work exactly as you want it to:
https://www.youtube.com/watch?v=okVqV-D7h0g