Oct 16, 2020 02:25 AM
Hi guys,
I’m struggling to get this formula validated, which is odd as it’s been validated by an Excel master…?
IF(
{User status}=“New sign-up no story”,
“Send new sign-up email”,
IF(
{User status}="New sign-up story in new”,
“Send new story email”,
IF(
{User status}=“Sign-up no story”,
“Send sign-up no story email”,
IF(
{User status}="Sign-up Story in new”,
“Send new story email”,
IF(
{User status}=“Sign-up Story in draft”,
“Send story in draft email”,
IF(
{User status}="Sign-up story in published”,
“Send post-publication email”,
“Nothing”
)
)
)
)
)
)
Oct 16, 2020 04:42 AM
Hi @Julien_Altoe!
I think this is just a text formatting issue with your quotation marks, but your code is fine. The quotations marks look mostly normal here, but when I copy and paste this formula, there are 2 types of quotation marks present. I just went through and replaced them all with standard quotations, and it worked fine for me.
Here’s the reformatted version, if it helps:
IF( {User status}="New sign-up no story", "Send new sign-up email", IF( {User status}="New sign-up story in new", "Send new story email", IF( {User status}="Sign-up no story", "Send sign-up no story email", IF( {User status}="Sign-up Story in new","Send new story email", IF( {User status}="Sign-up Story in draft", "Send story in draft email", IF( {User status}="Sign-up story in published", "Send post-publication email", "Nothing"))))))
Hope that helps. Welcome to the forums.
Oct 16, 2020 05:36 AM
Brilliant, thanks a lot for the help and the quick turnaround Nick, much appreciated!
Oct 16, 2020 02:01 PM
FYI You could do this a little cleaner with a single SWITCH()
statement instead of several IF()
s
SWITCH(
{User status},
"New sign-up no story",
"Send new sign-up email",
"New sign-up story in new",
"Send new story email",
"Sign-up no story",
"Send sign-up no story email",
"Sign-up Story in new",
"Send new story email",
"Sign-up Story in draft",
"Send story in draft email",
"Sign-up story in published",
"Send post-publication email",
"Nothing"
)
Oct 19, 2020 12:56 AM
Yes, I tried as well but obviously didn’t work either due to the wrong brackets.
Now it works, I shall definitely use that interesting SWITCH next time, many thanks!