SOLVED

New Contributor

# excel multiple and/or conditions with date data

I am able to retrieve data from D2 and E2 but I also want to have the same data included with D3 and E3 also. Is it possible to get multiple "date" data from Excel? Example below:

4 Replies

# Re: excel multiple and/or conditions with date data

I'm not sure I understand what you're trying to do, but perhaps

=IF(AND(OR(A2>=\$D\$2;B2<=\$E\$2);OR(A2>=\$D\$3;B2<=\$E\$3));"true";"false")

# Re: excel multiple and/or conditions with date data

I have tried it, but It gave me all of the data as "true".
For example: As you can see from the image, I want the red ones to be "false" because, they are not included between (01.03.2022/30.04.2022 and 01.06.2022/31.08.2022). I want to have the ones that belong inside that two certain dates as "true" not all of them.
I am wondering if it's possible to do such thing in Excel or not.

best response confirmed by ardamutlu (New Contributor)
Solution

# Re: excel multiple and/or conditions with date data

=IF(OR(AND(A2>=\$D\$2;B2<=\$E\$2);AND(A2>=\$D\$3;B2<=\$E\$3));"true";"false")

# Re: excel multiple and/or conditions with date data

Perfect! It works out just fine.

Thanks a lot! You are the best.