Mark the first row in a series of dates

DarkoDeign2

Board Regular
Joined
Jun 20, 2023
Messages
76
Office Version
  1. 365
Platform
  1. Windows
I have dates in col B.
In col E I would like to have a formula to indicate the first row of the same dates, as shown in the example below. How can I do this in the easiest way?

Book2
BE
2DateStatus
32023-07-26First
42023-07-26
52023-07-26
62023-07-26
7 
82023-08-02First
92023-08-02
102023-08-02
11 
122023-08-10First
132023-08-10
142023-08-10
152023-08-10
162023-08-10
Sheet1
Cell Formulas
RangeFormula
B3:B7,B11B3=IFERROR(IF('[Agenda & Minutes (2).xlsx]Agenda'!B3="","",'[Agenda & Minutes (2).xlsx]Agenda'!B3),"Error")
 

Excel Facts

Waterfall charts in Excel?
Office 365 customers have access to Waterfall charts since late 2016. They were added to Excel 2019.
Try a COUNTIF()=1? I'm assuming the same dates won't be found further down the range.
Book66
BE
1DateStatus
226-07-23First
326-07-23 
426-07-23 
526-07-23 
6 
702-08-23First
802-08-23 
902-08-23 
10 
1110-08-23First
1210-08-23 
1310-08-23 
1410-08-23 
1510-08-23 
Sheet1
Cell Formulas
RangeFormula
E2:E15E2=IF(COUNTIF(B$2:B2,B2)=1,"First","")


Or perhaps an ISNUMBER()

Book66
BE
1DateStatus
226-07-23First
326-07-23 
426-07-23 
526-07-23 
6 
702-08-23First
802-08-23 
902-08-23 
10 
1110-08-23First
1210-08-23 
1310-08-23 
1410-08-23 
1510-08-23 
Sheet1
Cell Formulas
RangeFormula
E2:E15E2=IF(ISNUMBER(B1),"","First")
 
Upvote 0
Hi,
When I try this I get "First" on all rows, I think this is because the dates are not typed manually, but pulled from another sheet with a formula.
 
Upvote 0
Hi,

I have tried both versions but I still think that it might be the dates in col B that is messing this up, since these dates are pulled from another sheet using a formula..

Cell Formulas
RangeFormula
E2:E14E2=IF(COUNTIF(B$2:B2,B2)=1,"First","")
F2:F14F2=IF(ISNUMBER(B1),"","First")
B2:B14B2='[Agenda & Minutes (2).xlsx]Test (4)'!$B3
 
Upvote 0
My guess as to why countif() is behaving that way is that you have date/time underlying values which isn't coming across in XL2BB?
I can't tell why ISNUMBER() isn't working if that is the case, however. Are your underlying values part text and part numbers by any chance?
 
Upvote 0
It works better after I got some help with the formulas in Col B.
B3 is the only cell with an actual date, the rest of the cells in B shows a date that is calculated.
Countif seems to count also the blank rows. Isnumber seems to work a little better, but here all the empty rows belows the rows with data shows First...

Cell Formulas
RangeFormula
E2:E12E2=IF(COUNTIF(B$2:B2,B2)=1,"First","")
F2:F12F2=IF(ISNUMBER(B1),"","First")
B3:B12B3=IF(D3="","",LOOKUP(9^9,B$2:B2)+7*(B2=""))
 
Upvote 0
Try this:

Book1
BE
1DateStatus
27/26/2023First
37/26/2023 
47/26/2023 
57/26/2023 
6 
7 
88/2/2023First
98/2/2023 
10 
118/10/2023First
128/10/2023 
138/10/2023 
148/10/2023 
158/10/2023 
Sheet1
Cell Formulas
RangeFormula
E2:E15E2=IF(AND(N(B1)=0,ISNUMBER(B2)),"First","")
 
Upvote 1
Solution

Forum statistics

Threads
1,224,827
Messages
6,181,194
Members
453,021
Latest member
pingpong7117

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