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
XiidaenXiidaen 

Time Based Workflow Question: Time based rule evaluation?

I was hoping that SFDC would add time based rule evaluation to the workflow capabilities.  That is, to run workflow rules without requiring the record to be modified first to trigger the rule.
 
My example is we allow some accounts be have a protected status as long as they have certain activity in a certain time period.  I've created the field that shows the days since said qualified activity occured, I have a workflow that will change the protected status based on the value in that qualified activity age field.
 
However, the rule only runs when someone modifies the account, so accounts can be falsely protected simply by not editing them.
 
I'm trying to find a way to make this rule run periodically without the modification.
 
Any suggestions?
 
Thanks,
 
Michael
Best Answer chosen by Admin (Salesforce Developers) 
smoodysmoody
"Because this workflow is created after those opportunities are created, so it can not work..."

This is time-based and it will work with dormant records. You don't have to edit to trigger these workflows. That being said, I haven't done specific testing on older records that have not been modified so I can't say for sure if that is the problem your seeing.

To edit, click on the Option link on the right of your post and there should be an edit option.

Message Edited by smoody on 03-19-2007 07:30 AM

All Answers

smoodysmoody
Time based workflow will be included in the Spring release. I'm not sure when that will be though.

CTU007CTU007
Spring 07 release is out, but after a quick look at the note, it seems to me that the trigger event has to be "created, edited, or not previously...."
 
Sounds like the so-called time-based workflow is not really time-based, my expection is that it is purely time-based, for example, if the rule is to send an alert 3 days before the opportunity close date, it should just happen without anybody editing the opportunity.
 
Of course I may be wrong. Will check further.
smoodysmoody
Well, I have been checking daily to see if the Time-Based Workflow
has been enabled and never saw anything different. I just looked up the release notes for the Spring Release and apparently there is a Time-Based Workflow now but it's VERY well hidden.

Make sure you read the release notes carefully. I'm still going through it and it's impossible to comprehend at first glance. It may take me a week of playing to get the hang of it.

Release Notes

One other thing to note, (I think this is where I was confused), This is only available to NEW workflow rules. If you want to use an exsisting rule, you must clone the rule to create a new one.

Edit: I may be wrong about that. You can't modify a timed-based workflow if it's Activated. You have to deactivate before changing it.

Message Edited by smoody on 03-14-2007 01:05 PM

Message Edited by smoody on 03-15-2007 08:58 AM

CTU007CTU007
I tried this new feature. It is not time-based workflow, it is time-based action only. Which means that the trigger criteria has still to be either create, or edit ....
 
So what I want to do is, I have some opportunities with a close date in the past and they are not closed yet, and I want to send an alert to the owner to update the close date, but if the owner does not edit the opportunity, this will not be triggered. Because this workflow is created after those opportunities are created, so it can not work....
 
BTW, how do I edit my messages? I dont see a edit link there?
smoodysmoody
"Because this workflow is created after those opportunities are created, so it can not work..."

This is time-based and it will work with dormant records. You don't have to edit to trigger these workflows. That being said, I haven't done specific testing on older records that have not been modified so I can't say for sure if that is the problem your seeing.

To edit, click on the Option link on the right of your post and there should be an edit option.

Message Edited by smoody on 03-19-2007 07:30 AM

This was selected as the best answer
CTU007CTU007
I can not see the "options" link on the right of my post when I was using "maxthon" browser, now I am using firefox and I can see it now. But the thing is, if I use IE7, the "option" link is not there, either. Sounds odd?

RajaramRajaram
As you are all aware, workflow rules get fired according to the evaluation criteria as well as the business condition you set up using the rule entres. Time-based workflow provide you the added ability to take time-dependent action to your rules. If you want to create reminders which notify the opportunity owner 7 days before the close date, you much creae a new rule. However, if you have existing workflow rules, you may be able to just update those rules and configure the time based actions you would like to take. If you create a new rule, you will notice that the actions section is divided in to 2 - Immediate actions and Time-dependent actions. Immediate actions are  what you currently have - actions executed as soon as the workflow rule is triggered. Time-dependent actions are those which you want to be executed at a later time.
I have posted a breeze presentation on the successforce web page. It should help you getting started with the feature.
Here is the breeze.
http://blogs.salesforce.com/features/2007/02/timebased_workf.html

Hope this helps.
Raja
XiidaenXiidaen
In my tests this appears to only react to action taken after a rule is evaluated, it does not evaluate the rule in the first place.

I'm looking for SFDC to provide an option that checks the rule conditions proactively, based on time, rather than when the record is touched or edited by a user.  I think that's the difference in what we're talking about.
neildneild

I've been reviewing the posts and the blog mention above but I haven't been able to find the answer to my question on time based rules.  I have set the rules so that if the case: date last modified is after 5 days and the case: status is waiting for customer feed back I want to notify the case: contact that the case will be closed.  Am I in the right place?  Should I be looking somewhere else?

Neil

 

RajaramRajaram
Hello,
 Hopefully this post will help you in understading and leveraging time-based workflow features to the fullest.
 http://community.salesforce.com/sforce/board/message?board.id=practices&message.id=3742


Raja
olkeitholkeith
Has anyone found a resolution to this?  What needs to happen is Salesforce giving the ability to schedule when a workflow rule is assessed. (Daily, Hourly, etc...)
olkeitholkeith
I have posted a new Idea on the Idea exchange.  Please Vote:
 
 
lsatonylsatony

CTU007 wrote:

So what I want to do is, I have some opportunities with a close date in the past and they are not closed yet, and I want to send an alert to the owner to update the close date, but if the owner does not edit the opportunity, this will not be triggered. Because this workflow is created after those opportunities are created, so it can not work....
 

This is EXACTLY what i've setup & I'm having the same problem - the email alert will not be sent unless the user edits the record.  Am I missing something?  Please let me know & thanks for your help.
CTU007CTU007
Isatony, I used excel to mass update those opportunities and the alerts were sent.
Then I created a validation rule that close date should always be a future date for open opps, so they should not be able to save the opp unless the date is in future.
Then I created a time-based task that one day after the close date, if the opp is still open, a task will be assigned to the owner to update the date.

Hope this helps.
lsatonylsatony
hello & thanks for getting back.


CTU007 wrote:

...I created a time-based task that one day after the close date, if the opp is still open, a task will be assigned to the owner to update the date.

Hope this helps.


If i add this time-based trigger now, will the alerts be sent even if the close date was, say a few weeks ago rather than just one day?

thanks again!
-t
RajaramRajaram
Hello,
Time-based workflow should be able to address your issue. You should create a workflow rule with say the criteria is "Opportunity: Closeed equals False", then create a time trigger which is say "2 days after close date" and create an email alert or a task to the opportunity owner.
After you create and activate this rule, all SUBSEQUENT opportunities will  have a  pending action  queued up. It is important to note that workflow rules are NOT retroactively fired on all existing  records. So, if you have an opportunity already in place, that will not have anything queues up. If you update it, the rule will be applied and the pending action should be queued up.

Hope this helps.

Raja

lsatonylsatony
H there,

Ok, so regardless of wether the workflow is immediate or time-based, the record will stil need to be edited for the notification to fire, correct?

if that is the case, should I find & mass update the records in question to get the initial action going - then subsequent actions will happen automatically?

thanks!
-t
CTU007CTU007
"if that is the case, should I find & mass update the records in question to get the initial action going - then subsequent actions will happen automatically?"
--- yes, I said I used excel connector to do it.

I suggest you follow my practice: use excel to mass update opps to trigger the alert(should not be time-based); set up a validation rule; and set up time-based alert.
lsatonylsatony
thanks again!

what value did you update in the opps using the excel connector?  or did you just do an export & import to update the "date modified"?

best,
-t
CTU007CTU007
Hi, you can just update any field, for example, opp name, no need to change it, just use "update selected cells", it will save the same value to the opp....
lsatonylsatony
OK - I'm on a Mac -is the excel connector the same as the data loader?
lsatonylsatony
Ok, I updated the records uing the data loader & the alerts & tasks were not created - what am i doing wrong?

my workflows are -

Notify opp owner if close date is within 7 days
Rule Criteria - Opportunity: Close Date equals NEXT 7 DAYS

Notify opp owner if close date has passed & stage is not closed
Rule Criteria - (Opportunity: Close Dateless thanTODAY) and (Opportunity: Stagenot equal toClosed Won) and (Opportunity: Stagenot equal toClosed Lost)

I've set these up to create a task & send an email to the record owner.

These are both immediate workflow actions.

Thanks again for everyone's help!



lsatonylsatony
Hi,

Does anyone have any insight as to why this is not working?

Thanks
PeanutmanPeanutman
Hi Isatony,
 
Today, Workflow Rules are only triggered if the update comes from a User, NOT the Data Loader.
 
Please click the link below and vote for my Idea which would give admins a choice when creating a Workflow Rule to have Users OR the Data Loader trigger it!
 

 
Thanks,
Eric


Message Edited by Peanutman on 03-07-2008 09:48 AM

Message Edited by Peanutman on 03-07-2008 09:48 AM
lsatonylsatony
hi there,

ok, cool - just promoted it.  is there any way to make this work for now w/ out manually editing / updating every record?

thanks:)
SaaniaSaania
We want to send an email to Opportunity Owner, if an Opportunity expires (that is, the Workflow triggers 7 days after Opportunity Close Date). I have created a Workflow with criteria of 'Closed equals False', then I added a time trigger to '7 days after Opportunity Close Date).

The problem is that if the Owner Closes the opportunity within those 7 days, the email still goes out. The problem is that the rule is triggered when the record is created or edited. So when the record was created, the above mentioned condition is true and an email alert is created, which goes out irrespective of subseqent changes to the record.


Thanks,
RajaramRajaram
Saania,
 That should not happen. If your rule is just Oppottunity: CLosed equals False. The moment the opportunity is closed, the pending action should be removed.
 You can verify this by going to Setup->Admin Setup->Monitoring->Time-based Workflow and search for the record.
 I just tested this and the entry does get removed.

 If the stage value fo the opty is a custom pickist value, make sure the stage values you use are mapped to a Closed Type.

Hope this helps..

Raja
SaaniaSaania
Thanks Rajaram,

The closed values (custom stages) were the problem in this case. The workflow is working fine now.

Thanks,

OldDeadBugOldDeadBug

I have a situation where a Custom Work Order object is associated with an Approval Process where each approval step updates the Work Order status, which allows the next step to proceed.

 

At one point, a partner assigns a date to a Scheduled Service field, and submits for an approval of the date. When the date is approved, the status changes to 'Schedule Approved'. 

 

At this point I have a time-based workflow which should change the status to 'In Implementation' on '0 days After the Scheduled Service Date' - which should mean at 12:00AM on that date or however many minutes after. 

 

My workflow rule crtieria is AND(ISPICKVAL(OrderStatus, 'Schedule Approved'),   ScheduledServiceDate < TODAY())

 

When I change the Status manually to Schedule Approved with a Service date of today, the Order gets queued. However if the status is changed when the Schedule is "Approved" by the customer, the update does not seem to queue the Work Order for the time based workflow. 

 

Why not? What is the difference between me updating a record with a new status, and an approval step field update updating the record? 

 

V

aiyaz_SFDCaiyaz_SFDC
I think yesterday I used a time based workflow rule unless i'm mistaken.  I created some custom Currency fields for an opportunity record.  I summed all these fields as long as some of them are greater than 0.  Once summed it would populate the total amount into the Standard Amount field.  This workflow retriggers on any change even if the criteria is already met from before.  Is this the time based rule evaluation or am I thinking of something else?
OldDeadBugOldDeadBug

I believe that's an Event-based workflow where you actually have to edit and save the record in order to trigger the change ( if its an "Every Time the record is created or edited" type). However you could probably have done the same thing using a formula field which would update in realtime regardless of whether you updated the record.

 

A time-based workflow is a different animal. Basically the cirteria enters the record into a queue for updating at some time in the future, for example a Scheduled event that might require an email notification at various times relative to the event date. 

 

However, apparently the criteria cannot be as a result of a previous workflow or approval update - for some reason the record doesn't get queued unless it is manually edited, or edited as a result of an APEX trigger. 

Vera BrettVera Brett

Hi...

 

I have the same question. Has anyone found a solution to this issue yet. 

OldDeadBugOldDeadBug
This is a long thread. To which issue are you referring?
tnstns

Has the issue with Time Dependent workflow actions not working been fixed yet?

Shamrock SnowmanShamrock Snowman

I'm brand new to the discussion boards, and I am also searching for an answer on these time-based workflow rules. 

I'm trying to enact changes and alerts that occur when a record has been dormant for 90 days.  Therefore, there is no creation or update of the record to trigger the rule - that's part of the reason I need the rule in the first place.

 

Does anyone have any answers yet?  Is there really no way for the workflow rules to look simply at time-based criteria without needing a record update to trigger the evaluation?

jbardetjbardet

Man, it's too bad you have to wait 3+ years to figure this out.

Shamrock SnowmanShamrock Snowman

What do you mean, jbardet?

jbardetjbardet

First request for true time based workflow rules was posted in this thread in March, 2007!

Shamrock SnowmanShamrock Snowman

Oh, I get it now.  It was a joke at my expense.  Well written, too.

 

Since I couldn't tell for sure by reading through the posts, I was merely hoping someone had a definitive answer as to whether or not this was possible, and if not, why.  And if there was anything in the works to add this functionality.

 

If anyone has some HELPFUL information, it would be much appreciated.

jbardetjbardet

I'm not sure what you mean about a joke at your expense. I really am disappointed in Salesforce that they have not addressed this issue (as far as I can tell from skimming this thread).

 

I can't tell if you're being sarcastic or not.

 

 

Anyway, good luck. I surely am no help here so I will leave.