0

I can't tell why I'm getting an error with the below formula:

=IF(AND(AL=AM, AK=TRUE), "Unchanged, " ", IF(AND(AL>AM, AK=TRUE), "Downgrade", " ", IF(AND(AL<AM, AK=TRUE), "Upgrade, " ")))

Columns AL and AM contain values 0-4. Column AK contains True/false. If the conditions are met I want to insert the text string. If they are not met, I want to insert the single space to leave the cell blank.

Thank you!

0

2 Answers 2

2

You need to put the nested IFs in the False of the previous:

=IF(AND(AL1=AM1, AK1), "Unchanged", IF(AND(AL1>AM1, AK1), "Downgrade", IF(AND(AL1<AM1, AK), "Upgrade", " ")))

Another method with out the AND():

IF(AK1,IF(L1=AM1,"Unchanged",IF(L1>AM1,"Downgrade",IF(L1<AM1,"Upgrade",""))),"")
Sign up to request clarification or add additional context in comments.

Comments

1

You don't need the " " after each of the text strings. The formula wasn't working because you were trying to define 4 parameters in each if statement. removing the ," " should fix this.

=IF(AND(AL=AM, AK=TRUE), "Unchanged, IF(AND(AL>AM, AK=TRUE), "Downgrade", IF(AND(AL<AM, AK=TRUE), "Upgrade, " ")))

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.