# I am using an IF function for a column but its giving me an error and I am not sure what the problem is. Can someone please help?

My formula:

``````
=IF(AND([Column 1]="Low",[Column 2]="Low"),
"No",

IF(AND([Column 1]="Low",[Column 2]="Medium"),"No",

IF(AND([Column 1]="Low",[Column 2]="Medium-High"),"No",

IF(AND([Column 1]="Low",[Column 2]="High"),
"No",

IF(AND([Column 1]="Medium",[Column 2]="Low"),
"Yes",

IF(AND([Column 1]="Medium",[Column 2]="Medium"),"No",

IF(AND([Column 1]="Medium",[Column 2]="Medium-High"),"No",

IF(AND([Column 1]="Medium",[Column 2]="High"),
"No",

IF(AND([Column 1]="Medium-High",[Column 2]="Low"),"Yes",

IF(AND([Column 1]="Medium-High",[Column 2]="Medium"),"Yes",

IF(AND([Column 1]="Medium-High",[Column 2]="Medium-High"),"No",

IF(AND([Column 1]="Medium-High",[Column 2]="High"),
"No",

IF(AND([Column 1]="High",[Column 2]="Low"),
"Yes",

IF(AND([Column 1]="High",[Column 2]="Medium"),"Yes",

IF(AND([Column 1]="High",[Column 2]="Medium-High"),"Yes",

IF(AND([Column 1]="High",[Column 2]="High"),
"No",
"INPUT MISSING"))))))))))))))))
``````
• What is the error? Where and when do you see the error? May 28, 2021 at 20:26
• Oh just figured it out. It was a timeout session. I though it is a syntax error. Thanks! May 28, 2021 at 21:30

You have to modify your formula to:

``````=IF(AND(A="Low",B="Low"),"No",
(IF(AND(A="Low",B="Medium"),"No",
(IF(AND(A="Low",B="Medium-High"),"No",
(IF(AND(A="Low",B="High"),"No",
(IF(AND(A="Medium",B="Low"),"Yes",
(IF(AND(A="Medium",B="Medium"),"No",
(IF(AND(A="Medium",B="Medium-High"),"No",
(IF(AND(A="Medium",B="High"),"No",
(IF(AND(A="Medium-High",B="Low"),"Yes",
(IF(AND(A="Medium-High",B="Medium"),"Yes",
(IF(AND(A="Medium-High",B="Medium-High"),"No",
(IF(AND(A="Medium-High",B="High"),"No",
(IF(AND(A="High",B="Low"),"Yes",
(IF(AND(A="High",B="Medium"),"Yes",
(IF(AND(A="High",B="Medium-High"),"Yes",
(IF(AND(A="High",B="High"),"No","INPUT MISSING")))))))))))))))))))))))))))))))
``````

The calculated column with above formula works normally on my end. 