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
aparna d 1aparna d 1 

MIXED_DML_OPERATION, DML operation on setup object is not permitted after you have updated a non-setup object (or vice versa)

Hi ALL,

I am  trying to Reactiving the Users using data loader but am getting below error .Please some one help on this, Thanks in advance

ERROR: UserValidateFederationId: execution of AfterUpdatecaused by: System.DmlException: Update failed. First exception on row 0 with id 0031Y00005obhRdQAI; first error: MIXED_DML_OPERATION, DML operation on setup object is not permitted after you have updated a non-setup object (or vice versa): Contact, original object: User: []Class.PC_UserHandler.pushUserValuesToContact: line 161, column 1Trigger.UserValidateFederationId: line 17, column 1
 
AbhishekAbhishek (Salesforce Developers) 
https://help.salesforce.com/articleView?id=000315345&type=1&mode=1

Check the workarounds as mentioned in the above official article.


For further reference, you can check the below,
https://developer.salesforce.com/forums/?id=906F00000008wAZIAY


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.