Combining around 4 If(AND) conditions giving error as
You've entered too many arguments for this function
The formula is here:
0=IF(AND(C2 = "Low", X2 <= 168), "Met", "Not Met",IF(AND(C2 = "Medium", X2 <= 96), "Met", "Not Met",IF(AND(C2 = "High", X2 <= 8), "Met", "Not Met",IF(AND(C2 = "Critical", X2 <= 4), "Met", "Not Met"))))
1 Answer
Generally
When you get the error You've entered too many arguments for this function than you don't use the allowed number of arguments. It may be helpfull to copy the whole line to notepad and check the arguments.
All functions with the allowed arguments can be found there:
Your special case
IF() accepts only three parameters, like:
=if(C2="A","is A", "is something else") You can take two decisions: "is A", "is something else".
To take three decisions you need nested IF(), expand it like this:
=if(C2="A","is A", if(C2="B", "is B", "is something else")) Now you can decide: "is A", "is B", "is something else".
To take four decisions expand it like this:
=if(C2="A","is A", if(C2="B", "is B", if(C2="C", "is C", "is something else"))) This is why you get the error. You are using more than three parameters:
=IF(AND(C2 = "Low", X2 <= 168), "Met", "Not Met",IF(AND(C2 = "Medium", X2 <= 96) Transform your statement the way above and it will work!
Edit:
To use a combination of AND() and OR() in an IF()-function, you may use someting like this:
=IF(OR(AND(C2 = "Low", X2 <= 168), AND(C2 = "Medium", X2 <= 96), AND(C2 = "High", X2 <= 20)), "MET", "NOT MET") 1