Solved

Rules Engine to update Engagement Type after all Escalation CTAs have been closed

  • 25 September 2021
  • 3 replies
  • 24 views

I’m looking for help on creating a Rule to update an Account’s Engagement Type after all Escalation CTAs have been closed.

If an Escalation CTA is closed, we want to update the Account’s Engagement Type to Established. That’s not a problem if there’s just one Escalation CTA open. What if there are multiple Escalation CTAs open?

How do you create the Rule if an Account has...

  • One Escalation CTA closed and 2 others are open, keep Engagement Type at Nurture
  • All 3 Escalation CTAs are now closed, update Engagement Type to Established

Thanks!

icon

Best answer by phani_kumar 27 September 2021, 15:18

View original

3 replies

Userlevel 4

Hey @edgarmsi, thank. you for your post. Forwarding this to the Product manager look into and get back to you. 

Userlevel 7
Badge +1

Hi @edgarmsi 

Yes, we can do that using our Rules Engine. Below are the steps to get the solution.

 

Step 1: using the Call to Action object get the Company GSID, Company Name, Call to Action Name, CTA Status with the required filters.

 

Step 2: using the previous step 1, create a transform task and calculate the Count of CTA Name with group by Company GSID with CTA Status = Open filter condition.

 

Step 3: using the previous step 1, create a transform task and calculate the Count of CTA Name with group by Company GSID with CTA Status = Closed filter condition.

 

Step 4: using the Company Object get the Company GSID and you can provide any filters like Company Status  = Active and ..etc.

 

Step 5: merge the Step 4 and Step 2 as Left Outer Join using the Company GSID as a Join Condition.

With this we will get the Company GSID, Count of CTA GSID name as open cta’s count.

 

Step 6: merge the step 5 and step 3 as Left Outer Join using the Company GSID as a Join Condition.

With this we will get the Company GSID, Open cta’s Count, and Count of CTA GSID nothing but Close cta’s count name as Closed cta’s Count.

 

So finally we have data with the fields like, Company GSID, Open CTA’s Count, and Closed CTA’s Count.

And the data looks like below.

Sample Data:

 

Here we are seeing Null data in few Id’s because we used the Left Join Condition in the Rule Setup.

So finally, based on that we can proceed with Rule Actions. You have to create multiple Actions based on the Open and Closed Counts.

If Open Count = Null And Closed Count != Null means that Company has 0Zero Open and All Closed CTA’s. So you can update Engagement Type to Established.

 

Hope this solves your use case.

Thanks.

Thanks @phani_kumar!  I understand your steps and will work to implement them. Thank you!

Reply