Home > Mobile >  Automatically number rows in Excel according the dates in column B
Automatically number rows in Excel according the dates in column B

Time:10-03

Automatically adding serial numbers in Excel is easy, but I would like to know if there is an easier way to add serial numbers only columns near new dates. I simple works, want to add serial numbers to each days, without any counting duplicates. Each date should be counted only once.

I am only able to achieve the following.

What I am getting, which wont work for my needs

But I would like to get the following results, just by dragging from the top column.

What I need, numbering according to new dates in column B

CodePudding user response:

Assuming the No. header is in A1, in A2:

=IF(B2<>B1,MAX(A$1:A1) 1,"")

and copied down.

CodePudding user response:

or may be it can help too

=IF(COUNTIF($B$2:B2,B2)>1,"",MAX($A$1:A1) 1)

  • Related