I've read several posts, but haven't found my exact question/answer. I have strings of several words in my SENDER column. I am creating a second column IF one of those words is Mickey or Minnie. I need to add about 5 more names and I have tried wording this different ways with IIF and with ELSEIF, etc, but I'm not quite getting it. Any thoughts on how to properly form this? Or is there an easier way? Thanks!
Solved! Go to Solution.
Hey @summarizer! You will want to try something like this:
IF CONTAINS([Sender],"MICKEY") THEN "MICKEY" ELSEIF CONTAINS([Sender],"MINNIE") THEN "MINNIE" ELSE NULL() ENDIF
This uses elseif statements of the ||. You can extend it to include your other names as well. Hope this helps!
You will need an IF ELSEIF ELSE statement
IF Contains([Sender], "MICKEY") THEN
"MICKEY"
ELSEIF Contains([Sender], "MINNIE") THEN
"MINNIE"
ELSE
Null()
ENDIF
Thank you both!
Thanks for your post, how do we write the script if we're using an In Database formula? Do we have to write three separate scripts, different wording, or can it only be written in a out of Database formula? Thank you, Chuck