Help

If And formula to check 2 conditional fields

Topic Labels: Formulas
Solved
Jump to Solution
447 2
cancel
Showing results for 
Search instead for 
Did you mean: 
kb1
4 - Data Explorer
4 - Data Explorer

Hi! I'm pretty new and having difficulty figuring out the logic of how to write this: 

  1. (single select) Status = "review 1" or "review 2" 
  2. (Long text) Feedback must not be blank 

If the above is true then it should provide an output of - "Ready!"

And then preferably the errors can drill down to the exact issue..

  • If the status is neither of those - Error, wrong status! 
  • If the feedback box is blank - Error, missing feedback! 

This seems simple but I can't seem to figure out the correct formatting to return correct results. Help appreciated 😄 

1 Solution

Accepted Solutions
Arthur_Tutt
8 - Airtable Astronomer
8 - Airtable Astronomer

Hey @kb1 yeah there's a few nested IF statements here that can make the logic and syntax a bit messy. I drafted something up that should work for you (will need to update my variable names to match your field names).

Sample table setup and desired output:

Screenshot 2023-11-05 083814.png

Formula:

IF(
  NOT({Feedback}),
  "Error, missing feedback!",
  IF(
    NOT(
      OR(
        {Status} = "Review 1", {Status} = "Review 2"
      )
    ),
    "Error, wrong status!",
    IF(
      AND(
        OR(
          {Status} = "Review 1", {Status} = "Review 2"
        ), {Feedback}
      ), 
      "Ready!"
    )
  )
)
  

Screenshot 2023-11-05 083847.png

Let me know if this works for you!

 

See Solution in Thread

2 Replies 2
Arthur_Tutt
8 - Airtable Astronomer
8 - Airtable Astronomer

Hey @kb1 yeah there's a few nested IF statements here that can make the logic and syntax a bit messy. I drafted something up that should work for you (will need to update my variable names to match your field names).

Sample table setup and desired output:

Screenshot 2023-11-05 083814.png

Formula:

IF(
  NOT({Feedback}),
  "Error, missing feedback!",
  IF(
    NOT(
      OR(
        {Status} = "Review 1", {Status} = "Review 2"
      )
    ),
    "Error, wrong status!",
    IF(
      AND(
        OR(
          {Status} = "Review 1", {Status} = "Review 2"
        ), {Feedback}
      ), 
      "Ready!"
    )
  )
)
  

Screenshot 2023-11-05 083847.png

Let me know if this works for you!

 

kb1
4 - Data Explorer
4 - Data Explorer

Thank you so much for the help @Arthur_Tutt That worked beautifully 🙂