2

Suppose I have a record that is created with status X, and I need to check it 60 days later if it still has the same status. If it is X, then change it to Y.

I think this is doable with time-based workflow rules, but I don't know whether the workflow will be fired if the status is changed before the 60 days or not. If the status is changed to Y before the 60 days, the workflow can not fire.

I've been searching for a while now, and I couldn't find anything that clears this doubt. I would like not to use Apex for this, if possible, but I know that I can create a class that runs everyday and checks this.

1 Answer 1

4

See the Time-Based Workflow FAQ:

Will the pending actions in the queue ALWAYS trigger?

No. Time-dependent actions remain in the Workflow Queue until processed or the rule criteria for the Workflow Rule are evaluated as "false." If a record no longer matches the rule criteria when the rule is evaluated, Salesforce removes the time-dependent actions queued for that record.

  • Example: An Opportunity Workflow Rule may specify:
    • A criteria set to "Opportunity: Status not equals to Closed Won, Closed Lost."
    • An associated time-dependent action with a time trigger set to 7 days before the Opportunity close date. If a record matching the criteria is created on July 1st and the Close Date is set to July 30th, the time-dependent action is scheduled for July 23rd. However, if the Opportunity is set to "Closed Won" or "Closed Lost" before July 23rd, the time-dependent action is automatically removed from the queue.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .