将IF功能与OR功能组合以允许多个条件 [英] Combine IF function with OR function to allow multiple conditions
本文介绍了将IF功能与OR功能组合以允许多个条件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
= IF(L2 =,活动,IF(K2 <= I2,准时),IF(K2> I2,晚了)))
,但现在我需要检查 F
列中的多个条件 我尝试过 OR
>
= IF(OR(F2 =计划,F2 =3小时30分钟,IF(L2 = ,活动,IF(K2 <= I2,准时,IF(K2> I2,Late)))),其他)
我的资料
如何检查只有服务= F2 =计划,F2 =3小时30分钟或如果L2为空否则检查是否迟到还是准时?
解决方案
可能是这样吗?
= IF(OR(F2 =计划,F2 =3小时30分钟,L2 =),活动,
IF(K2 <= I2,On Time,IF(K2> I2,Late,Other)))
但是可能会简化,因为其他案例似乎不可能:
= IF(OR(F2 =Scheduled,F2 =3 Hours 30 Minutes,L2 =),Active,
IF(K2 <= I2,On Time晚))
I have been using =IF(L2="","Active",IF(K2<=I2,"On Time",IF(K2>I2,"Late")))
which worked, but now I need to check multiple conditions on F
column
I have tried OR
function
=IF(OR(F2="Scheduled",F2="3 Hours 30 Minutes",IF(L2="","Active",IF(K2<=I2,"On Time",IF(K2>I2,"Late")))),"Other")
My Data
How do I check if only service = F2="Scheduled",F2="3 Hours 30 Minutes" or if L2 is empty else check if its Late or On Time?
解决方案
May be this?
=IF(OR(F2="Scheduled",F2="3 Hours 30 Minutes", L2=""),"Active",
IF(K2<=I2, "On Time", IF(K2>I2, "Late","Other")))
But it can probably be simplified because the "Other" case seems impossible:
=IF(OR(F2="Scheduled",F2="3 Hours 30 Minutes", L2=""),"Active",
IF(K2<=I2, "On Time", "Late"))
这篇关于将IF功能与OR功能组合以允许多个条件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文