Creating Groups from a Segment of Text in Text Field
Hello!
I would like to create groups based on a “contains” value in a text field. Since this is not an available option, I think I am going to need to use a formula to create a field that I can group by.
Objective: Create a conditional formula that will select a drop-down based on conditions.
Sample Data:
What I would like to happen:
If Campaign Name contains “PF_MU30_Weekly” Change Email Type to “Weekly”
If Campaign Name contains “PF_MU30_ReEngagement” change Email Type to “ReEngagement”
If Campaign Name contains “PF_MU30_Engagement” change Email Type to “Engagement”
From here then I can group by the Email Type field.
A Single-Select field (i.e. “dropdown”) cannot contain a formula. Only a formula-type field can contain a formula. If you don’t care about the “Email Type” field being a dropdown menu, then you can make it a Formula type field and use this formula:
IF(SEARCH("PF_MU30_Weekly",Name),
"Weekly",
IF(SEARCH("PF_MU30_ReEngagement",Name),
"ReEngagement",
IF(SEARCH("PF_MU30_Engagement",Name),
"Engagement"
)
)
)
If you need that to be a dropdown column, then there are some other possibilities, but it will be more complex and possibly involve an automation.
A Single-Select field (i.e. “dropdown”) cannot contain a formula. Only a formula-type field can contain a formula. If you don’t care about the “Email Type” field being a dropdown menu, then you can make it a Formula type field and use this formula:
IF(SEARCH("PF_MU30_Weekly",Name),
"Weekly",
IF(SEARCH("PF_MU30_ReEngagement",Name),
"ReEngagement",
IF(SEARCH("PF_MU30_Engagement",Name),
"Engagement"
)
)
)
If you need that to be a dropdown column, then there are some other possibilities, but it will be more complex and possibly involve an automation.
Hello Nathaniel! Thank you for the quick response!
I am getting this error when I paste your recommendation:
Hello Nathaniel! Thank you for the quick response!
I am getting this error when I paste your recommendation:
Hi again,
yes, you’ll need to change the word “Name” in the formula to be your column’s name, which I believe is “Campaign Name” from your photo. Since that has a space in it, it needs to be wrapped in curly braces: