Using multiple IF function to based on two columns and bring TRUE or FALSE in the third column

Using multiple IF function to based on two columns and bring TRUE or FALSE in the third column

I am using a large amount of data. After using Match Index formula I get a small amount of data then filter them to get the sheet like attached picture in below.

picture 1

Column C is showing if the road is wet or dry and column D showing rainfall in millimeter. I want to say if road is wet and rainfall is >0 the result is TRUE or if road is Dry and rainfall is =0 the result is TRUE, otherwise result is FALSE. I am trying to use formula like below but it is not working.

=IF(D27=0,AND(C27="Dry",TRUE,IF(D27>0,AND(C27="Wet",TRUE),FALSE)))

I want the result be like this:

result picture

答案1

IF(OR(AND(D27=0,C27="Dry"), AND(D27>0, C27="Wet")), TRUE, FALSE)

相关内容