Skip to main content

When DML operations on certain sObjects sometimes referred to as setup objects (such as a User Object), along with, on the non-setup object (such as Accounts), in the same transaction, then, a Mixed DML error is thrown at a User.

 

This article will show you how to use Process Builder to avoid getting a Mixed DML Operation Error.

 

First, I will perform DML operation on Setup (User) and non-Setup (a Custom Object called Leave Balance) Objects in the same transaction.  This will generate a Mixed DML Operation error because one cannot perform a DML operation on Setup and non-Setup objects in the same transaction.

 

Next, I will show you how to use Time-dependent/Scheduled Action, in the Process Builder, to perform DML operations on Setup and non-Setup Objects in the same Process without incurring a Mixed DML operation error. The time-dependent/scheduled action is used because it helps in separating DML operations on Setup and non-Setup objects.

[New Post] Getting Started with Process Builder – Part 64 (How to fix MIXED_DML_OPERATION error )

1 comment
0/9000