Ronderbecke
Board Regular
- Joined
- Oct 4, 2017
- Messages
- 73
I am trying to compare a date in a cell to get closest without going over so that it pulls the correct data but its not working? I know I'm doing something wrong but cannot figure out how to fix it. Here is the formula I am using:
=index(query(B3:C4,"select B where C>=DATE'"&TEXT(C3,"yyyy-MM-dd")))
The data looks like this:
I want to compare the dates so that the 8/9/2021 shows 8/1/2021 and the 9/30/2021 shows the 9/17/2021 (so that its always the previous or equal to the date of change. Am I even using the right formula for this?
=index(query(B3:C4,"select B where C>=DATE'"&TEXT(C3,"yyyy-MM-dd")))
The data looks like this:
Dates of change | Date of sale |
8/1/2021 | 8/9/2021 |
9/17/2021 | 9/30/2021 |
12/13/2021 | |
1/17/2022 |