Skip to main content
We have a need to use "if this, then that" logic within the contact filtering of a CoPilot powerlist. Here is the situation:





We have two different "Roles with Company" that designate the contacts on an account that need to be informed of key information: Primary Technical and Decision Maker. A contact can only have one role at a time, but there can be multiple contacts with the same role on an account. We are working toward our SOC2 certification and have some notices that need to be delivered in a certain timeframe to certain customer. All of our accounts (should) have either a primary technical contact or a decision maker, but not necessarily both. For some notices, we would like to be able to say the following:





"If there is at least one primary technical, then send the notice to those contacts and DO NOT send a notice to the decision maker roles.


If there is not at least one primary technical, then send the notice to the contacts with the decision maker role"





Our predicament now is that some accounts are setup with CEO or CIO individuals as decision maker. We have gotten complaints that those individuals are annoyed by the notice, thus we are trying to solve that in situations where we can.





Any ideas?
Hi Ben,





One possible way to do this would be to use a custom MDA object and bionic rules to populate the MDA object. You could essentially first create the list of contacts in the MDA object by including all accounts that have a technical contact and then add to that list of contacts in MDA by outer join on only the accounts that don't have a technical contact (pulling in the decision maker). 





This would allow you to skip any decision maker contacts on accounts where a technical contact is present. 





Then use this MDA object to create your powerlist. 





If you haven't started using bionic rules yet, here is a great article, along with some example use cases. Here is another article with a sample bionic rule on aggregation. And in case you missed it - the product release webinar discussing bionic rules and data management.
+1 to Dan's comment.  This is a 'bionic' use case.  We don't yet have the bionic tech directly embedded into CoPilot but you can use Bionic Rules to make the calculations and then create the powerlist as a separate step.   One addition to Dan's comment: you wouldn't necessarily have to add the data into a new object in MDA, you could populate a new field on the Contact.  E.g. if you had a Key Info Recipient checkbox then you run a bionic rule to figure out who is such a person and then the Powerlist becomes trivial to build. 
If you wish to do this with a custom rule, you could try out the following steps:





Rules Engine




  • Create a custom Number field called '# of Primary Technicals' in Gainsight's 'CustomerInfo' object, with 'Default Value = 0'.

  • Build a custom rule on the 'Contact' object.

  • Pull in the 'Account Id' and also do a COUNT aggregation on 'Contact Id'.

  • Apply a filter for 'Role = Primary Technical'. 

  • The output of this query would be a list of Accounts along with the count of how many Primary Technicals each Account has.

  • Pick the 'Load to Customers' action.

  • Map 'Account Id' to 'Account Id'.

  • Map the COUNT to the custom field that you created in the beginning.

  • Run one-time or create a schedule that works for you.
CoPilot




  • Build your CoPilot PowerList with the following criteria:
                [a] Contact -> Role = Primary Technical


                [b] Contact -> Role = Decision Maker


                [c] CustomerInfo -> # of Primary Technicals = 0





                A OR (B AND C)





Hope this helps!
That is a great workflow. I thought I had it, but I am encountering an odd issue when adding that number field to the CustomerInfo object. It seemingly lets me add it and click the "add" button. Immediately following I do see it in the list of fields for the CustomerInfo object. But, if I navigate away, it disappears from the list and never returns. Thus, when I try to use that for the Rules Engine, it is not displaying.





Any ideas why this would happen or what I am missing?





Thanks!
Scratch that. I think I just forgot to hit Save on the Schema. Trying that again.
Great! Let me know how it goes.
Worked great once I saved it. Thanks again!
I may have spoken too soon. Now for some reason I am not seeing my new field as available when working in CoPilot. I know the data was populated into the field as my Rule succeed.





Do you have to do something separate to enable a field for CoPilot?
Looks like your rule is loading data into an MDA table called Customer Info, which is different from our object in Salesforce. You'd have to go to 'Salesforce Setup -> Create -> Objects -> Customer Info' and create the field there. You can then change your rule action to 'Load to Customers' and map again.

Reply