Aug 03 2021 08:42 PM
Dear Friends,
Kindly help me the below error,
i have written the IF condition like
0.50 > GREEN, Refer the column - j2>=0.50, t2>=0.50, "green",
0< RED, Refer the column - j2<=0, t2<=0, "red",
0.49 to 0 , AMBER refer the column - j2<=0.49, t2<=0.49, "Amber".
=IFS(OR(J2>=0.5, T2>=0.5),"GREEN",OR(J2<=0.01,T2<=0.01),"RED",OR(J2<=0.49, T2<=0.49),"AMBER").
when i try this same i am getting error, values 0.03 suppose this should be AMBER but its shows RED i have attached this same image . please help me the issue.
Aug 03 2021 10:31 PM - edited Aug 03 2021 10:32 PM
@SUDHAKAR-FRONTIER You need to use AND in stead of OR.
This formula will result in AMBER in U2.
=IFS(AND(J2>=0.5, T2>=0.5),"GREEN",AND(J2<=0.01,T2<=0.01),"RED",AND(J2<=0.49, T2<=0.49),"AMBER")
Aug 04 2021 08:50 AM
Aug 04 2021 08:54 AM
@SUDHAKAR-FRONTIER An image is no good. I'd need the file to look at.
Aug 04 2021 09:01 AM
Please find the Attached file.
If possible kindly help (b2<=10.00, c2<=10.00) "GREEN +",
Between 50 to 10 need to display Green.
Aug 04 2021 09:13 AM
@SUDHAKAR-FRONTIER Well, with this data it seems that OR in all three conditions works as intended. It didn't when I replicated the data from your initial data set.
Aug 04 2021 09:25 AM
Still same error, Suppose the highlighted cases to be Amber but its coming RED. same attached below
Aug 04 2021 12:13 PM
@SUDHAKAR-FRONTIER Your problem is that these rows qualify for two if the three criteria when you use OR. The IFS function stops evaluating the formula as soon as a criteria is met.
When you use AND, some rows will return #N/A as none of the criteria are met. Make sure that all possible criteria are correctly set and that there is no overlap between them.