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
softcloudsoftcloud 

Re-run the Leads assignment rules

What is the best way to re-run the assignment rules on existing Leads? So we have the existing Leads which have been created in the past before we setup assignment rules. Now, we would like to assign these Leads to the proper owner.

Can we use Data Loader and do update on the record

werewolfwerewolf
Yes, if you turn on AssignmentRuleHeader and touch some field in those leads.  I'm not sure how you turn on that header in the Data Loader but I'm almost certain there's a way to do so.
softcloud2009softcloud2009

The help section on salesforce also mentioned that we can re-run the assignment rules through update using data loader. However, when I tried, it didn't work. It seems that it only work for insert in data loader.

 

Here is the help text on salesforce when I searched for assignment rules:

 

"When using the Data Loader to insert or update Leads or Cases and assignment rules are in place to assign to queues etc. how do I ensure that assignment rules are triggered, once data is loaded?

To ensure assignment rules are triggered, follow the instructions below:

1. Ensure your assignment rule is active and in place. Obtain the active assignment rule ID. Lead or Case depending on what data is being inserted or updated.

2. Prior to loading data open the Data Loader:
Click Settings (this opens the Data Loader settings pop up) in the Assignment rule box. Enter the assignment rule ID previously obtained and click OK.

3. Then insert or update data as you normally would using the Data Loader. The Assignment rule will trigger as long as the rule is met.

Note: Assignment rule ID's will differ for Leads and Cases."

jkucerajkucera

You could export the leads, delete those leads using data loader, and then insert them again.

 

Alternately, you could implement code to run assignment rules upon lead update as mentioned in this post:

 http://community.salesforce.com/sforce/board/message?board.id=apex&message.id=26532