We have an event trigger that's throwing an error for 1 specific user. We've tested with similar users that have: same assigned profile and role and license and we tried creating the meeting on the same accounts. It works for others but not this one specific user.
This is the error when the one user attempts to save a meeting:
Validation Errors While Saving Record(s) There were custom validation error(s) encountered while saving the affected record(s). The first validation error encountered was Apex trigger ActivityTrigger caused an unexpected exception, contact your administrator: ActivityTrigger: execution of BeforeUpdate caused by: System.QueryException: List has no rows for assignment to SObject: Trigger.ActivityTrigger: line 8, column 1.
Click here to return to the previous page.
This is the line 8 thats causing the issue; it's just a SOQL call to get a system user id :
ID DataAdmin = [Select id from User where name = 'Data Admin' limit 1].id;
Any ideas why only this user retrieves an empty list when looking up this user account? I am able to put in the static id and that does work.