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
Alex Valavanis 10Alex Valavanis 10 

User ID does not exist

Hello,

I am trying to find the name of user ID "00520000004FxxP" and can't find it (i created a user report and exported all users both active and inactive).

I received an Appex Application error saying the below and trying to investigate. Any ideas?

Apex script unhandled trigger exception by user 00520000004FxxP

Opportunity:execution of BeforeUpdate
caused by:System.QueryException:sObject type 'Product_c' is not supported.

Class.OpportunityTriggerHandler.populateFields: Line 59, Column 1
Trigger.Opportunity:line 17, column 1
ANUTEJANUTEJ (Salesforce Developers) 
Hi Alex,

OpportunityTriggerHandler can you check where the error is occurring?

also, can you try the below soql to get the user information also try checking if you have all the correct permissions?

>> SELECT Id, Username, LastName, FirstName, Name, CompanyName FROM User WHERE id = '00520000004FxxP'

Let me know if it helps you and close your query by marking it as solved so that it can help others in the future.  

Thanks.
Alex Valavanis 10Alex Valavanis 10
Hello @ANUTEJ,

Apologies but i am new to this - What do you mean by to try the below soql? I can found this from workbench, correct?

Also the emai error I received is this -  Does this help?

"Opportunity: Opportunity: execution of BeforeUpdate caused by:
System.QueryExecution: sObject type 'Product_c' is not supported.
Class.opportunityTriggerHandler.populateFields:line ...

Apex script unhandled trigger exception by user 00520000004FxxP

Opportunity:execution of BeforeUpdate
caused by:System.QueryException:sObject type 'Product_c' is not supported.

Class.OpportunityTriggerHandler.populateFields: Line 59, Column 1
Trigger.Opportunity:line 17, column 1"
Todd KadasTodd Kadas
just had same issue.  Apex error email.  Attempted to query user id.  Zero records returned in dev console.  Am sys admin