Bring the first date prior to a date

phil133

Active Member
Joined
May 5, 2015
Messages
257
Office Version
  1. 365
Platform
  1. Windows
Hi. I have a column (A) with dates sorted by oldest to nearest. I also have another column (B) with dates but with gaps of 4 or 5 weeks between them. I would like to have a formula on another column that will bring me the first date in column B if that date is prior to column A.
An example so you can understand.
ABC
18/1/200617/1/200614/2/2006
19/1/200614/2/200614/2/2006
10/2/200614/3/200614/2/2006
13/2/200618/4/200614/2/2006
14/2/200616/5/200614/3/2006
15/2/200620/6/200614/3/2006
13/3/200618/7/200614/3/2006
14/3/200615/8/200618/4/2006
15/3/200619/9/200618/4/2006

<tbody>
</tbody>
Column C is my goal. C1 is 14/2/2006 because A1 is after B1. So he looks at B2 which is after A1 so it's good. C2 the same logic. C5 is 14/3/2006 because A5 is 14/2/2006 which is not prior to 14/2/2006 (When it's the same date I would like the next date). etc.

Hope you understand what I'm trying to do!
Thanks for any help!
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
Hi, is this it maybe?


Excel 2013/2016
ABC
1ABC
218/01/200617/01/200614/02/2006
319/01/200614/02/200614/02/2006
410/02/200614/03/200614/02/2006
513/02/200618/04/200614/02/2006
614/02/200616/05/200614/03/2006
715/02/200620/06/200614/03/2006
813/03/200618/07/200614/03/2006
914/03/200615/08/200618/04/2006
1015/03/200619/09/200618/04/2006
Sheet1
Cell Formulas
RangeFormula
C2=INDEX($B$2:$B$10,MATCH(TRUE,INDEX($B$2:$B$10>A2,0),0))
 
Upvote 0

Forum statistics

Threads
1,215,446
Messages
6,124,904
Members
449,194
Latest member
JayEggleton

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top