Skip to main content


Showing posts from October, 2016

Process Builder not working during record insertion and fail to launch Flow

I created Process Builder to automatically add user into Chatter group , refer to here .It works fine when I update the user but it fail when I create new user. An error occurred at element Add_User_to_All_Chatter_Group (FlowRecordCreate). INSERT --- INSERT FAILED --- ERRORS : (MIXED_DML_OPERATION) DML operation on setup object is not permitted after you have updated a non-setup object (or vice versa): CollaborationGroupMember, original object: User I am assuming during creation, the user id is not yet committed, so it not able to set variable in Flow.After do some googling , I found some solution that can be applied on my case. I also add new Record Lookup in my Flow, to check if the user already exist in Chatter group and Decision when the Lookup Result is not found. Good thing, due to this I can remove custom field that I used to indicate if the User already added into the group. In Process Builder , I use Scheduled Actions so I have to use  'Formula evaluates