I have a list of stores nationally with email addresses. They are broken down into 2 regions, 10 counties and 20 clusters.
“I have” = There is no schema to worry about, my table is perfect (?)
“I have” = There is a list written somewhere that I need to make a table of (?)
If you want to do this from anywhere in your app, SELECT() is the fastest approach
Better formulas depends heavily on what your schema is.
But it’s not hard at all. Just be aware that if you have to store the list you will need an EnumList base type Email and if you want to directly send to a list from Bot you can just have a formula returning a list of emails
To shed a little more light…it is assumed you have a table, pretend it’s called Emails, that has the list of emails addresses along with all of the qualifying details to classify the email by Region, County and Cluster.
Next it is presumed that you have a second table where you someway choose the Region, County and Cluster and upon Save of this row, you want to trigger an Automation that sends an email to all email addresses associated with those chosen attributes.
In your Automation Bot you will have a task for sending an email and in that task is a property named “To” (see image from Task)
In this To field you can insert an expression to choose the list of emails (click the flask icon). Now since you said you choose “either a region, a county or a cluster”, I would use an expression like this:
NOTE: Simply adjust the IFS() options if you find you need to set other attributes to identify the list of emails. The same basic pattern will still apply.