Welcome to the community, @Embrace_Your_Hustle!
You technically don’t need a nested IF statement, because logical argument #2 will ALWAYS be true if logical argument #1 fails.
So your formula would be pretty simple… it would look like this:
IF(
OR({Date},{Location}="Outside Area"), "Yes", "No"
)
Thank you so much @ScottWorld!
I was completely over complicating it. :grinning_face_with_sweat:
Thank you so much @ScottWorld!
I was completely over complicating it. :grinning_face_with_sweat:
Haha, you’re welcome!
Hi @ScottWorld, I got the formula to work in my test table, but had trouble making it work in my production environment. The concept is the same, but the column names are different, which I wouldn’t think would make a difference as long as they are updated. I figured it out though, someone had entered a space after the text in the single select text option. Is there a way to add a wildcard/like operator to the = text area?
IF(
OR({Date},{Location}=“Outside Area”), “Yes”, “No”`
)
Also, is the first part of the logic checking for to confirm whether the Date field is blank?
Thanks again!
Hi @ScottWorld, I got the formula to work in my test table, but had trouble making it work in my production environment. The concept is the same, but the column names are different, which I wouldn’t think would make a difference as long as they are updated. I figured it out though, someone had entered a space after the text in the single select text option. Is there a way to add a wildcard/like operator to the = text area?
IF(
OR({Date},{Location}=“Outside Area”), “Yes”, “No”`
)
Also, is the first part of the logic checking for to confirm whether the Date field is blank?
Thanks again!
Yes, that’s what {Date} on its own is checking for. The existence of data there.
Hi @ScottWorld, I got the formula to work in my test table, but had trouble making it work in my production environment. The concept is the same, but the column names are different, which I wouldn’t think would make a difference as long as they are updated. I figured it out though, someone had entered a space after the text in the single select text option. Is there a way to add a wildcard/like operator to the = text area?
IF(
OR({Date},{Location}=“Outside Area”), “Yes”, “No”`
)
Also, is the first part of the logic checking for to confirm whether the Date field is blank?
Thanks again!
I noticed that this part of your follow-up wasn’t answered. Airtable doesn’t currently support wildcards or other means of pattern matching (i.e. regular expressions). The closest it has are the FIND()
and SEARCH()
functions, either of which would work in your situation. Here’s the updated formula using FIND()
:
IF(OR(Date, FIND("Outside Area", Location)), "Yes", "No")
This also adds the ever-so-slight optimization of removing unnecessary curly braces from around the field names. Curly braces are not required for single-word field names, as long as they don’t contain special characters. A field name that’s only numbers, or one that contains spaces or special characters, will require braces around it in your formulas.