Add incremental number based on conditions in Excel

Solved/Closed
Rruwinda - Jan 19, 2017 at 06:31 AM
Mazzaropi Posts 1985 Registration date Monday August 16, 2010 Status Contributor Last seen May 24, 2023 - Jan 20, 2017 at 12:08 PM
Hello,

I have a column that contains variables (for example; days of the week) and I am trying to add an incremental number in the second column based on the first finding duplicates in the first column.

This is what I am looking for:

Column A Column B
Monday 1
Monday 2
Monday 3
Monday 4
Tuesday 1
Tuesday 2
Tuesday 3
Wednesday 1
Wednesday 2
Wednesday 3
Wednesday 4

Looking forward to hear some advices!
Related:

2 responses

Mazzaropi Posts 1985 Registration date Monday August 16, 2010 Status Contributor Last seen May 24, 2023 147
Updated by Mazzaropi on 19/01/17 at 07:36 AM
Rruwinda, Good morning.

Try to use:

B1 --> =IF(A1="","",COUNTIF($A$1:A1, $A1))

Copy it down.

Is that what you want?
I hope it helps.
--
Belo Horizonte, Brasil.
Marcílio Lobão
2
Hello Mazzaropi,
Thanks a lot! You solved it!
0
Mazzaropi Posts 1985 Registration date Monday August 16, 2010 Status Contributor Last seen May 24, 2023 147
Jan 20, 2017 at 12:08 PM
Thanks for the feedback.

I'm glad to be of help.
--
Belo Horizonte, Brasil.
Marcílio Lobão
0