We have a Formula Field named My Team on User object which uses the logged in User and Manager Id of the user record to populate YES or NO. This field is used in a report as a filter. So if a Manager logs in and runs this report he will see YES for all the users for whom he is the manager and NO for other. This way a manager can see his Team members on the report by including a filter My Team = YES.
Here is the formula syntax:
IF(Manager.Id = $User.Id ,'Yes', 'No')
The report and the associated Dashboards are taking long time to run due to huge amount data fetched. When we raised the case, one of suggestions from Salesforce was to replace this Formula Field with a Workflow Rule or Trigger. My question is, is it really possible to populate this with WF Rule of Trigger. If yes then can anyone guide me on the how part? The values need to change based on the logged in user.