I need logic to choose a certain calculation based on two possible criteria.
The first criteria is:
- If column B = "Partial"
- If columns C and D are greater than 20%
- Then return column E.
- Else If C and D are less than 20 percent then return 1.
The second criteria is:
- If column C and D are greater than 20%
- Then return column E
- Else return column F.
So far I have the following, but I return #VALUE!:
=IF(OR(AND(B2="Partial",C2>0.2,D2>0.2)),E2,1),IF(OR(AND(C2>0.2,D2>0.2)),E2,F2)
CodePudding user response:
IF only allows three arguments and you are trying to do more, instead combine them:
=IF(AND(C2>0.2,D2>0.2),E2,IF(B2="Partial",1,F2))