Email escalation off custom field

I've watched Jeff's video on Escalations and read the Sys Admin Guide, but I'm still not clear how to achieve the following.  I'd be grateful for any guidance you care to share.  Thanks.

1. create custom Date field on Opportunity, e.g. oppo_followupdate

2. add the field to the New Opportunity workflow step

3. write escalation rule that will email the Assigned Rep a reminder 1 day prior to the follow-up date

4. as the field is updated, e.g. to 2 weeks later, insert a new escalation, and so on

Parents
  • 0

    Hi R Graham

    My first question is how comfortable are you with creating new fields and creating / edit Workflow Rules as they are the basics here, or are you needing steps for everything?

  • 0 in reply to Matthew Shaw

    Thanks Matthew, good point, I should have been more clear in what I'm asking help with.  I've been working with Sage CRM since 2005, with SQL Server and programming since before that. I'm comfortable adding fields, creating workflows, writing Javascript for both server and client-side, including table scripts.  I just haven't done much with Escalation rules, for whatever reason.  So I can implement a solution that requires writing the SQL to insert a new record into the Escalations table, e.g. from a tablescript, either PostInsertRecord() or UpdateRecord().  I just don't have a good sense of what the overall model should look like, nor with what the escalation itself would look like.  Again, it's not just a first escalation, but the repeating escalations as future email alerts are sent out.  Thanks for whatever insight you can share, I appreciate it.

  • 0 in reply to R Graham MacLeod

    I hate type in example code in here as it always errors, as the forum doesn't like something. so here is a picture of my reply for you ;) (though error in the last line where the executing SQL should have a where of oppo_opportunityid = #oppo_opportunityid#) 

  • 0 in reply to Matthew Shaw

    Thanks so much, Matthew, this is really helpful!  I understand the importance of the stop field, and to reset it via a 2nd action in the escalation, right after sending the email.  My escalation rule would have to have a DateDiff between current date and the value of the oppo_followupdate field.  It would get triggered when the DateDiff is one day.  As for using a trigger, I'd probably insert the new Escalation record as part of a PostInsert() tablescript.    If I do that, I would also have to insert the child Action records, yes?  Maybe that's what I was missing.  Once inserted, my subsequent updates would only be to the stop field.  So as a user updates the oppo_followupdate field, the UpdateRecord() tablescript would reset the stop field.  To summarize: insert new Escalation record and related Actions when new Opp is created, via PostInsertRecord() script, then use UpdateRecord() script to reset the stop field.  I'll try that and let you know how it goes.  It seems to me a simple yet useful feature.  Thanks again, your suggestions were just what I was looking for!

Reply
  • 0 in reply to Matthew Shaw

    Thanks so much, Matthew, this is really helpful!  I understand the importance of the stop field, and to reset it via a 2nd action in the escalation, right after sending the email.  My escalation rule would have to have a DateDiff between current date and the value of the oppo_followupdate field.  It would get triggered when the DateDiff is one day.  As for using a trigger, I'd probably insert the new Escalation record as part of a PostInsert() tablescript.    If I do that, I would also have to insert the child Action records, yes?  Maybe that's what I was missing.  Once inserted, my subsequent updates would only be to the stop field.  So as a user updates the oppo_followupdate field, the UpdateRecord() tablescript would reset the stop field.  To summarize: insert new Escalation record and related Actions when new Opp is created, via PostInsertRecord() script, then use UpdateRecord() script to reset the stop field.  I'll try that and let you know how it goes.  It seems to me a simple yet useful feature.  Thanks again, your suggestions were just what I was looking for!

Children
No Data