Forum Discussion

Zuceth's avatar
Zuceth
Copper Contributor
Oct 12, 2023
Solved

Combining IF, AND and OR statements

I am trying to combine these two formulas together =IF(AND(A1="vacant",B1="c"),1,0) and =IF(AND(A1="vacant",B1="d"),1,0). Basically what I want is IF A1 is vacant position and B1 is D or C, true. If...
  • HansVogelaar's avatar
    Oct 12, 2023

    Zuceth 

    =AND(A1="vacant", OR(B1={"C", "D"}))

     

    or if you prefer

     

    =IF(AND(A1="vacant", OR(B1={"C", "D"})), 1, 0)

     

    or even

     

    =(A1="vacant")*OR(B1={"C", "D"})